This is a discussion on Customising the PHP Error Handler within the PHP Programming forums, part of the Web Development category; Guys, Customising the PHP Error Handler Introduction One of the last areas that developers seem to deal with in their ...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
| |||
| Guys, Customising the PHP Error Handler Introduction One of the last areas that developers seem to deal with in their code is error handling. I am not talking here about errors with user input where it is a simple matter to display an error message and ask for new input, I am taking about the kind of error over which the user has absolutely no control and which may cause the current PHP script to stop running. In this situation you as a developer need to know some details about the error otherwise you will have a very difficult time in locating the source of the error so that you can fix it. Developers new to PHP often complain there there is no proper error handling in the language. This is utter nonsense. All the functionality is there, you just have to customise it to your specific requirements. In this tutorial I will show to how to create an error handler that will: • Trap all errors whether triggered by PHP or a specific function call. • Filter all errors depending on their error level. • Output a formatted error message to the user. • Send an email to the system administrator. • Write the error details to a separate log file. Creating the Error Handler Refer:Customizing the PHP Error Handler - Creating the Error Handler Regards sivaraman Last edited by Booom : 08-27-2007 at 04:27 PM. |
| Sponsored Links |
![]() |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Error: command line error MIDL1001 : cannot open input file wincodec.idl midl | Mramesh | C# Programming | 0 | 02-18-2008 11:07 PM |
| Customizing the PHP Error Handler | Sabari | PHP Programming | 2 | 12-18-2007 05:53 AM |
| Can I set up my own JavaScript error handler? | itbarota | HTML, CSS and Javascript Coding Techniques | 1 | 09-13-2007 03:07 AM |
| Can I dynamically change the JavaScript error handler? | itbarota | HTML, CSS and Javascript Coding Techniques | 1 | 09-13-2007 03:04 AM |
| example of Server.Transfer and Context Handler | hanusoft | ASP and ASP.NET Programming | 1 | 09-06-2007 07:08 AM |