<html>
<! UserErrorHandler.inc                                       >
<! Chapter 9, Oracle Database XE PHP Web Programming          >
<! by Michael McLaughlin                                      >
<!                                                            >
<! This script is a user-defined error handler as a library   >
<! file.                                                      >
<head>
<title>
  Chapter 9 : UserErrorHandler.inc
</title>
</head>
<body>
<?php
  // Override the error level.
  function user_error_handler($e_number,$e_string,$e_file,$e_line)
  {
    switch ($e_number)
    {
      case E_USER_ERROR:
        print "This is the User Defined Error [".$e_string."]<br>";
        break;
      case E_USER_WARNING:
        print "This is the User Defined Warning [".$e_string."]<br>";
        break;
      case E_USER_NOTICE:
        print "This is the User Defined Notice [".$e_string."]<br>";
        break;
    }
  }
?>
</body>
</html>
