您当前的位置:首页 > 网站建设 > php
| php | asp | css | H5 | javascript | Mysql | Dreamweaver | Delphi | 网站维护 | 帝国cms | React | 考试系统 | ajax | jQuery |

PHP restore_exception_handler() 函数

51自学网 2023-01-07 20:39:59
  php

定义和用法

restore_exception_handler() 函数恢复之前的异常处理程序。

该函数用于在通过 set_exception_handler() 函数改变后恢复之前的异常处理程序。

该函数总是返回 TRUE。

语法

restore_exception_handler()

提示和注释

提示:之前的异常处理程序可能是在内建的异常处理程序或用户自定义函数中构建的。

实例

<?phprestore_exception_handler();throw new Exception('Uncaught Exception occured');?>

上面代码的输出如下所示:

Fatal error: Uncaught exception 'Exception' with message'Uncaught Exception occured' in C:webfoldertest.php:4Stack trace: #0 {main} thrown in C:webfoldertest.php on line 4


下载地址:
PHP restore_error_handler() 函数
PHP set_error_handler() 函数
51自学网,即我要自学网,自学EXCEL、自学PS、自学CAD、自学C语言、自学css3实例,是一个通过网络自主学习工作技能的自学平台,网友喜欢的软件自学网站。
京ICP备13026421号-1