Last active
June 13, 2019 11:04
-
-
Save jahid32/c44f34628ac5904d637ffb4de4231f70 to your computer and use it in GitHub Desktop.
WordPress Debug log
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if (!function_exists('write_log')) { | |
function write_log ( $log ) { | |
if ( true === WP_DEBUG ) { | |
if ( is_array( $log ) || is_object( $log ) ) { | |
error_log( print_r( $log, true ) ); | |
} else { | |
error_log( $log ); | |
} | |
} | |
} | |
} | |
define( 'WP_DEBUG', true ); | |
define( 'WP_DEBUG_LOG', true ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment