WordPress调试模式开启和设置操作方法
在开发WordPress 主题的时候务必要开启Debug 模式(调试模式),以便检测出隐藏在前端页面背后的bug。下面就为大家简单介绍一下开启的方法。
在WordPress 根目录下的wp-config.php 文件大概75行下有下面一段代码:
1 2 3 4 5 6 7 8 |
/**
* For developers: WordPress debugging mode.
*
* Change this to true to enable the display of notices during development.
* It is strongly recommended that plugin and theme developers use WP_DEBUG
* in their development environments.
*/
define('WP_DEBUG', false);
|
按照其说明,将 false 改成ture 就可以开启调试模式。
那么,在什么地方可以看到Debug 的提示呢?
这样子就可以根据提示来修改bug了。



客服微信

还没有任何评论,你来说两句吧