Home  >  Article  >  Backend Development  >  When using Gii to generate code in Yii, I encounter "Setting unknown property: yiiwebApplication::gii"

When using Gii to generate code in Yii, I encounter "Setting unknown property: yiiwebApplication::gii"

WBOY
WBOYOriginal
2016-07-29 08:56:111805browse

??

When using Gii to generate code in Yii, I encountered "Setting unknown property: yiiwebApplication::gii"

For the use of Gii: http://www.yiichina.com/doc/guide/2.0/ start-gii and https://github.com/yiisoft/yii2/blob/master/docs/guide/start-gii.md, I put the following paragraph directly in $config = [. . . 】; inside, and then encountered "Setting unknown property: yiiwebApplication::gii".

<span>'gii' => [
    'class' => 'yii\gii\Module',
    'allowedIPs' => ['127.0.0.1', '::1', '192.168.0.*', '192.168.178.20'] // adjust this to your needs
],</span>

Then I tried to put this code in "

$config['modules']['gii' ] = [
'class'=>

<span>$config['modules']['gii'] = [
        'class' => 'yii\gii\Module',
    	'allowedIPs' => ['127.0.0.1', '::1', '192.168.0.*', '10.231.113.187']
    ];</span>
So this document is still ambiguous.
The above introduces the "Setting unknown property: yiiwebApplication::gii" encountered when using Gii to generate code in Yii, including the relevant content. I hope it will be helpful to friends who are interested in PHP tutorials.

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn