yii2-debug
github地址:https://github.com/yiisoft/yii2-debug/blob/master/docs/guide-zh-CN/installation.md
步骤说明
例:开启后台debug
1、保证后台入口文件index.php中调试模式开启
defined('YII_DEBUG') or define('YII_DEBUG', true);
defined('YII_ENV') or define('YII_ENV', 'dev');
2、配置appadmin/config/main-loacl.php如下
if (YII_ENV_DEV) {
// configuration adjustments for 'dev' environment
$config['bootstrap'][] = 'debug';
$config['modules']['debug'] = [
'class' => 'yii\debug\Module',
// uncomment the following to add your IP if you are not connecting from localhost.
'allowedIPs' => ['*.*.*.*', '127.0.0.1', '::1'],
];
$config['bootstrap'][] = 'gii';
$config['modules']['gii'] = [
'class' => 'yii\gii\Module',
// uncomment the following to add your IP if you are not connecting from localhost.
'allowedIPs' => ['*.*.*.*', '127.0.0.1', '::1'],
];
}
原配置为
if (YII_ENV_DEV) {
// configuration adjustments for 'dev' environment
$config['bootstrap'][] = 'debug';
$config['modules']['debug'] = 'yii\debug\Module';
$config['bootstrap'][] = 'gii';
$config['modules']['gii'] = 'yii\gii\Module';
}
记升级fecshop 1.6 最新版本
debug 设置了以上配置,yii-debug工具条确还未显示
appserver 入口报错如下
上图报错,是runtime目录下debug没有写入权限。
更改权限还是没有显示
appadmin 入口报错如下


本文由 Axin 创作,采用 知识共享署名 3.0 中国大陆许可协议 进行许可。
可自由转载、引用,但需署名作者且注明文章出处。