Is it possible to write a custom error handler function?
Now if there is an error on my website, then the server prints it into the result html. But I would like to create an error handler function instead.
function errorhandler($error) {
echo '<span class="e">'.$error.'</span>';
}
// rest of the PHP file...