![]() |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
PHP Errors, Warning, Notices
Did you receive this kind of PHP errors or something similar ?
Parse error: syntax error, unexpected T_ECHO in ... Parse error: syntax error, unexpected ')' Parse error: syntax error, unexpected '>', expecting T_VARIABLE or '$ When you are developing an PHP application of course you can make pass some errors which will malfunction the functionality of your application and you have to debug it. It is a good practice to trace this errors, to handle them and to repair. This can be done in entire developing process, by some testers after main development deadline or by the end users by sending bug reports which can be fixed in next versions of the application. There are several types of errors in PHP. Depending of the type you can set some parameters which errors to be displayed, and for which not. First you have to set 'display_errors' parameter which global affect all type of errors to display him or not to display anything. It is good to turn on this parameter while developing and to turn off when the application is ready and already works for the end users. The 'display_errors' parameter can be set trough PHP.INI, by '.htaccess' file or within the current application with:
<?php
Next parameter which you have to set is 'error_reporting'.
<?php error_reporting(E_ALL); ?> error_reporting() can accept one value and exactly this value will set which kind of errors will be reported. Please see the next example:
<?php
In next table I will show you all PHP error types, their order with their value levels for using it with error_reporting() and their descriptions.
Next Tutorials
Post Comment |
Need a specific tutorial? Do not hesitate and submit a request! |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Home | Sitemap |
Terms & Privacy
© ONLINEHOWTO.net 2006-2010 |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||