I’ve recently moved from CakePHP to Yii and I’m having some URL/routing problems.
I have a controller named, for example, myController and have a couple of requirements.
I want a nice URL like ‘my-controller’, or ‘mycontroller’.
I want to be able to do something like /my-controller/some-path/action
In order to do this I created the following routes:
‘/my-controller/some-path/<action>’ => ‘myController/<action>’
They seem to work OK, but then I started using widget/actions (i.e. test.action) and the routes aren’t working for the ‘/my-controller/some-path/’. I just get a 404.
Also, with the urlManager -> urlFormat set to ‘path’ I can’t pass parameters to the controller with the / as opposed to name=value pairs. Again, I get a 404.