In the Yii structure, the main configuration file defines the components. one of which is urlManager:
'urlManager'=>array( 'urlFormat'=>'path', 'showScriptName'=>false, 'rules'=>array('/'=>'site/homepage',
cool I like it working. Now I am creating a module and this module, I want to have some routing rules that are specific to the module. I want / myModule / moduleController / action /: id to point to an action and pass the identifier along with it. but I donβt want to touch files outside the module. I think you can do this in myModuleModule.php file.
I found the link http://www.yiiframework.com/forum/index.php/topic/25801-url-rules-in-module-definition/ about one way to do this, but it seems to be hacked and not perfect.
So my question is: what is the best way to add urlManger rules to a module?
source share