When programming errors occur, the debugger will be displayed. This can happen for a variety of reasons, and it is the job of the debugger to help you pinpoint the error so that you can fix it quickly.
When the debugger, pictured in Figure 1, is displayed, you will be supplied with some basic information about the error, which contains the error message, the line number on which it occurred, the file in which it occurred, and the type of error that was produced. You can use this information to locate the specific error quickly.
In addition to the basic information displayed, a full backtrace will be displayed. This is a reverse-chronological breakdown of the steps the application took before the error occurred. It is produced by the built-in PHP function debug_backtrace(). Refer to the PHP documentation for full details on how to interpret this output.
Sometimes the debugger doesn't display. This usually happens when PHP encounters an error before the framework has even been engaged. Other times, errors bubble in a way that the framework cannot intercept them. It is recommended that you develop in an environment where you can set the error reporting in the php.ini, that way all errors will be displayed, even the ones the framework can't handle.
© Copyright 2010 negative11.com