我需要创建 debug.log,但由于某种原因它没有创建。
我尝试过的事情:
define( 'WP_DEBUG', true );
define( 'WP_DEBUG_DISPLAY', true );
define( 'WP_DEBUG_LOG', '/tmp/wp-errors.log' );
希望结局很好 :D
一定存在权限错误,导致无法将日志文件写入
/tmp/
。
使用
define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true);
define( 'WP_DEBUG_DISPLAY', false );
让 WordPress 将默认的 Debug.log 文件写入
/wp-content/
。