Installer wrote:Mark -
Having error_reporting off won't prevent a script from halting on fatal errors, and it won't prevent setting up custom error handlers (which should be done in any case). Maybe I misread your post.
No, you're right. Perhaps I should clarify it:
My custom error handlers respect the current level of error_reporting and will only terminate the script if the current error falls inside error_reporting.
This makes it possible for me to carry out operations which are expected to generate warnings (e.g. parsing tagsoup HTML) without them being interrupted by my error handler. To do this, I temporarily set the error_reporting level lower.
I also occasionally use the @ operator, but I feel it should be used sparingly as it can lead to very difficult to debug faults.
I appreciate that display_errors and error_reporting are independent. In fact error_reporting only really affects the default error handler, which isn't even called if you set up a custom one. Except that in mine, I maintain this behaviour.
My error handler typically halts on ANY unmasked error, not just fatals (which it can't trap anyway). This stops the "charging headlong into oblivion" system.
Mark