Re: Custom error handlers and error reporting levels.
| From: | Zeev Suraski | Date: | Sat, 23 Dec 2000 02:32:19 +0000 |
| Subject: | Re: Custom error handlers and error reporting levels. | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-42161@lists.php.net to get a copy of this message | ||
At 03:08 22/12/2000, Zak Greant wrote:
Behavior of error_reporting when combined with custom error handlers seems a bit odd. Even if the E_USER_... error reporting levels have been explicitly disabled using error_reporting, the custom error handler will still be called. Is this the desired behavior?Yes, it's the intended behavior. error_reporting instructs the builtin error handler how to behave. Your error handler can choose to pay attention to it or not. You can easily pay attention to it using a single line of code in the beginning of it - if (!($type & error_reporting())) return; Zeev -- Zeev Suraski <zeev@zend.com> CTO & co-founder, Zend Technologies Ltd. http://www.zend.com/