Whenever there is a call to an undefined function, no errors are logged. Instead the script just stops executing. To make things worse, if I run php -l filename.php, It shows that there are no syntax errors. I am using a custom error handler function, but even the first line is never reached.
How can I get it to run my error handler when there is a call to an undefined function?
I am using PHP 5.3.2-1. Here is the code that is setting the error handler:
error_reporting(-1);
$old_error_handler = set_error_handler( "userErrorHandler" );
set_exception_handler('exception_handler');
Neither the error handler nor the exception handler are being reached, although they do work for other errors.
The reason I want this is I end up having to place debug statements in my code to see how far it gets before it stops executing which is a slow process compared to an error message that would tell me the file and line number where the error is.