

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