Skip to content

Instantly share code, notes, and snippets.

@lorenzocaum
Last active January 30, 2017 00:36
Show Gist options
  • Save lorenzocaum/848801a1173be464fbe7 to your computer and use it in GitHub Desktop.
Save lorenzocaum/848801a1173be464fbe7 to your computer and use it in GitHub Desktop.
Enable WordPress debugging with debug log on and debug display on
<?php
//* Do NOT include the opening php tag
//* Enable WordPress debugging with debug log and debug display
define('WP_DEBUG', true);
if (WP_DEBUG) {
define('WP_DEBUG_LOG', true);
define('WP_DEBUG_DISPLAY', true);
}
@lorenzocaum
Copy link
Author

Here is an example of how to disable debugging via your wp-config.php file.

<?php
//* Do NOT include the opening php tag

//* Disable WordPress debugging with debug log and debug display
define('WP_DEBUG', false);
  if (WP_DEBUG) {
    define('WP_DEBUG_LOG', true);
    define('WP_DEBUG_DISPLAY', true);
}

@lorenzocaum
Copy link
Author

Here is an example of how to enabled WP debugging with debug log through your wp-config.php file.

//* Enable WordPress debugging with debug log and debug display
define('WP_DEBUG', true);
  if (WP_DEBUG) {
    define('WP_DEBUG_LOG', true);
    define('WP_DEBUG_DISPLAY', false);
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment