Display Errors in PHP Script

Some web servers have PHP display_errors turned off by default for security reason. This is good for security, but make debug very hard.

To display errors in PHP script, add following code to PHP script

error_reporting(E_ALL);
ini_set('display_errors', '1');

Posted in PHP