How to turn on error reporting for testing your website?

Sets error reporting to true in wordpress indicates which PHP errors are reported
Comment out the top line there, and add the rest to your wp-config.php file to get more detailed error reporting from your WordPress site. Definitely don't do this live, do it for local development and testing.
// define('WP_DEBUG', false); define('WP_DEBUG', true); define('WP_DEBUG_LOG', true); define('WP_DEBUG_DISPLAY', false); @ini_set('display_errors', 0);
This changes will be done in wp-config.php
This will log all errors notices and warnings to a file called debug.log in wp-content (if Apache does not have write permission, you may need to create the file first and set the appropriate permissions (i.e. use 666) )
No comments:
Post a Comment