Answers for "through error on warning php"

PHP
0

through error on warning php

function exception_error_handler($severity, $message, $file, $line) {
    if (!(error_reporting() & $severity)) {
        // This error code is not included in error_reporting
        return;
    }
    throw new ErrorException($message, 0, $severity, $file, $line);
}
set_error_handler("exception_error_handler");
Posted by: Guest on July-11-2021

Browse Popular Code Answers by Language