- var_dump: documentation ( source)
- error_reporting: documentation ( source)
- set_error_handler: documentation ( source)
<?php
/*
final public ExceptionException::getPrevious ( void )
*/
error_reporting(E_ALL);
function exception_error_handler($errno, $errstr, $errfile, $errline ) {
throw new ErrorException($errstr, '00007600', $errno, $errfile, $errline);
}
set_error_handler("exception_error_handler");
try {
echo $x;
}
catch(Exception $e) {
var_dump($e->toString());
}