Created
July 8, 2014 06:41
-
-
Save brianr/db44a4efb99d00d0c4b1 to your computer and use it in GitHub Desktop.
Rollbar with custom php error handler
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| Rollbar::init($config, true, false); // config array, true to install uncaught exception handler, false to not install error handler | |
| function my_error_handler($errno, $errstr, $errfile, $errline) { | |
| Rollbar::report_php_error($errno, $errstr, $errfile, $errline); | |
| // add your own error handling code here | |
| } | |
| set_error_handler('my_error_handler'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment