For debugging php code, its often nice to have the errors printed for you on a specific directory that might be your development area, but leave you production area free of error codes. To turn on errors for a specific directory, I tried the following and it worked out quite well:

    php_flag display_errors 1

You also have the option of putting the php_flag display_errors 1 in a .htaccess file if you do not have access to the Apache configuration files (assuming your hosting service reads the .htaccess file).

comments powered by Disqus