YII 创建后台模块

1,在protected/config/main.php目录下修改如下目录

'modules'=>array(
// uncomment the following to enable the Gii tool

'gii'=>array(
'class'=>'system.gii.GiiModule',
'password'=>'xw0987',
// If removed, Gii defaults to localhost only. Edit carefully to taste.
'ipFilters'=>array('127.0.0.1','::1'),
),

),

2,通过路由访问 创建后台模块

  “http://localhost/YII/shop/index.php?r=gii/default/login”

3,键入密码

4生成模块

 5,点击Preview预览  勾选要生成的模块

6.generate生成

7.查看项目列表多出bgModel  

创建成功

 

你可能感兴趣的:(yii)