I've been developing web application based on Yii framework.
I've faced with troubles on trying to make sef urls.
What I have:
config is set up.
'urlManager'=>array( 'urlFormat'=>'path', 'showScriptName'=>false, 'rules'=>array( // rules go here ) )
This is code which is used for tesing:
echo $this->createUrl('site/test', array('help'=>'me')
$this - is controller.
If I'm living 'rules' array in config empty I'm getting this /site/test/help/me. I expected this.
If
'rules'=>array(
'<controller:\w+>/<action:\w+>' => '<controller>/<action>',
)
I'm getting /site/test?help=me which is also expected.
But if
'rules'=>array(
'<controller:\w+>/<action:\w+>' => '<controller>/<action>',
'<controller:\w+>/<action:\w+>/<help:\w+>' => '<controller>/<action>/<help>',
)
I'm still getting /site/test?help=me. I expected to see /site/test/me
Could anyone help me?
Thanks in advance.