PHP Reporting Errors

To get PHP error reporting for a file or web application use one of the following methods:
1. Add the following to the PHP code in the file:

error_reporting(E_ALL);
ini_set(‘display_errors’, ’1′);

2. Add the following to a .htaccess file in the same directory:

php_flag display_errors on
php_value error_reporting 2039

3. Edit the server php.ini file setting:

display_errors = On
error_reporting = E_ALL & ~E_NOTICE

Post comment