Tag: php_flag html_errors
Enable PHP Error Messages
by Grant Burton on Nov.29, 2008, under PHP
PHP errors should be turned off on a live site, but occassionally it is useful for debugging purposes to display any error messages. Depending on the type of hosting, you can generally use one of the following methods:
- Edit the site’s php.ini file
error_reporting = E_ALL
display_errors = OnE_ALL = All errors and warnings, as supported, except of level E_STRICT in PHP < 6.
- Alternatively, you can use an .htaccess file
php_flag display_startup_errors on
php_flag display_errors on
php_flag html_errors on
Make sure to turn the “On” values to “Off” once you are done to prevent any visitors from seeing the errors.