
解决方法:
加上 'allowedIPs'=>['*']即可。
(推荐教程:yii框架)
如下:
if (!YII_ENV_TEST) {
// configuration adjustments for 'dev' environment
$config['bootstrap'][] = 'debug';
$config['modules']['debug'] = [
'class' => 'yii\debug\Module',
'allowedIPs'=>['*']
];
$config['bootstrap'][] = 'gii';
$config['modules']['gii'] = [
'class' => 'yii\gii\Module',
'allowedIPs'=>['*']
];
}更多编程相关内容,请关注php中文网编程入门栏目!










