Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

trigger_error()

trigger_error() is a PHP native function, which raises an error, in the style of PHP engine. It can raise notice, warning, deprecated and error.

<?php

    echo $a;

    trigger_error('This is a warning, that says: Undefined variable $x', E_USER_WARNING);

?>

Documentation

See Also