PHP restore_error_handler() Function

PHP restore_error_handler Function


Definition :

The restore_error_handler() is inbuilt function in php.This function restores the previous error handler function. This function is used after changing the error handler function using set_error_handler(). to revert to the previous error handler (which could be the built-in or a user defined function).

Syntax of restore_error_handler () :

       restore_error_handler()

Given below example shows the usage of restore_error_handler() function.

Output :

My ERROR [1024] A custom error has been triggered
Error on line 18 in file C:\xampp\htdocs\php\php error\restore_error_handler().php
Aborting...