Hi I am tring to enable php error logging file in wordpress. I added the following code into wp-config.php. However the php does not log anything into the log file. I have added rw permission to others for the file php_errors.log file permission already. What am i missing here.? //The following is excerpt from wp-config.php: @ini_set('error_log','/home/kentzo/php_errors.log'); //if WP_DEBUG_LOG is true, the log file will be wp-content/debug.log @ini_set('display_errors',0); if( 'kentzo_momo_wp' === DB_USER ){ define('WP_DEBUG', true); // Turn debugging ON define('WP_DEBUG_DISPLAY', false); // Turn forced display OFF define('WP_DEBUG_LOG', false); // Turn logging to wp-content/debug.log ON, this will overwrite the error_logs above } / That's all, stop editing! Happy blogging. / /* Absolute path to the WordPress directory. / if ( !defined('ABSPATH') )
asked 19 Sep '11, 10:15 kentzo |
You need to add the logging PHP configuration to a .htaccess or php.ini file depending on which server you are on. answered 19 Sep '11, 13:41 timg ♦♦ Thank you. It works after i define a php.ini in my application folder. I just have define the two directives and it works for me now. display_errors=0 log_errors=On
(20 Sep '11, 08:30)
kentzo
|