Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Turning on Debug mode in wp-config.php
* When you are building your code (i.e. in development), you should turn on
* all error reporting in wp-config.php. Why? Because you want to find all
* warnings, notices, errors, etc. before you ship it to your client. Even
* the minor errors are telling you something is wrong in the code.
* Suppressing them does not fix the problem. It merely quiets them down.
* @link
// turns on the WordPress debug mode. It will then show all PHP errors,
// notices, and warnings. You want to see these when you are building and testing.
define('WP_DEBUG', true);
// will save the errors into a debug.log file inside of your wp-content folder.
// It gives you a record of the errors to help you to find the problems.
define( 'WP_DEBUG_LOG', true );
// will show the errors on the pages. If you set it to false, then all
// errors are hidden.
define( 'WP_DEBUG_DISPLAY', true );
// forces WordPress to load the full version of scripts and stylesheets
// rather than the minified versions. That’s handy in debug/build mode.
define( 'SCRIPT_DEBUG', true );
// Uncomment when you are working on profiling and tuning performance.
// define( 'SAVEQUERIES', true );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.