我已經使用Gii創建了一個模塊(教育)。該模塊有三個動作(索引,讀取,寫入)在其中的一個控制器(文章)。如何訪問模塊控制器動作
我訪問模塊是這樣的:
http://example.com/index.php/education/article/index(工作正常)
http://example.com/index.php/education/article/read(重定向到 索引操作)
http://example.com/index.php/education/article/write(重定向到 索引操作)
所以問題是,我可以在文章控制器只能訪問指數行動。當我嘗試訪問任何其他操作時,它總是重定向到索引的操作。
我在配置以下項/主:
'modules'=>array(
// uncomment the following to enable the Gii tool
'gii'=>array(
'class'=>'system.gii.GiiModule',
'password'=>'password',
'ipFilters'=>array('127.0.0.1','::1'),
),
'education'
),
任何想法是什麼問題?
請檢查accessRules文章 –
在文章控制器中沒有實現訪問規則。 – Awan
向我們展示您的代碼:讀取或寫入操作以及url配置 – soju