Error Handling Learning Mode
What will this code output?
<?php
$handler = function($errorNumber, $errorMessage, $file, $line) {
echo "Error [$errorNumber] in [$file] at line [$line]:
'[$errorMessage]'\r\n";
};
set_error_handler($handler);
try {
echo $a;
session_start();
echo session_id();
} catch (Throwable $e) {
echo "Error caught!";
}
|
|
|
|