執行 ❯
獲取您
自己的 PHP
伺服器
×
更改方向
更改主題,深色/淺色
前往 Spaces
<!DOCTYPE html> <html> <body> <?php // A user-defined exception handler function function myException($exception) { echo "<b>Exception:</b> ", $exception->getMessage(); } // Set user-defined exception handler function set_exception_handler("myException"); // Throw exception throw new Exception("Uncaught exception occurred!"); ?> </body> </html>