I am trying to replace the built-in php shutdown_function with a custom one.
It works fine, however, it still displays the original error (built-in error) over my new error message.
<?php function shutdown_output() { $error = error_get_last(); if($error !== NULL) { echo "ERROR"; exit(); } else { echo "NO ERROR"; } }
Any ideas?
source share