Advertisement
urosevic

WordPress: WP_DEBUG to wp-content/debug.log

Feb 11th, 2015
495
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.46 KB | None | 0 0
  1. /**
  2.  * This will log all errors notices and warnings to a file called debug.log in
  3.  * wp-content only when WP_DEBUG is true. if Apache does not have write permission,
  4.  * you may need to create the file first and set the appropriate permissions (i.e. use 666).
  5.  */
  6.  
  7. define( 'WP_DEBUG', true ); // Or false
  8. if ( WP_DEBUG ) {
  9.     define( 'WP_DEBUG_LOG', true );
  10.     define( 'WP_DEBUG_DISPLAY', false );
  11.     @ini_set( 'display_errors', 0 );
  12.     error_reporting(E_ALL);
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement