我是yii框架的新手。我使用gii工具构建了Category Moudles,我必须输入以下URL
http://localhost:8080/myadminpanel/index.php/category/category/create
这里,一个类别是模块ID,另一个类别是控制器ID。我如何制作以下网址
http://localhost:8080/myadminpanel/index.php/category/create
答案 0 :(得分:0)
我假设你知道在哪里定义routes:
'rules' => array(
'category/create' => '/category/category/create' // For the "create" action
'category/<action:w\+>' => '/category/category/<action>' // For all category routes
)