Url Parsing And Createurl

Hey Guys, My config looks like this:


                        '<controller:\w+>/<id:\d+>/<action:\w+>(/<subId:\d+>)?' => '<controller>/<action>',

                        '<controller:\w+>/<id:\d+>/(.*)?' => '<controller>/view',


This allows me to do some things like


and things like


and it works for incoming requests. But when I do the following:

// CGridView







I get:*)?

So this is probably something that I’ve done wrong. Any thoughts to help a guy out? Or should I start building my own slugs. i.e


public function getSlug(){

// build slug


Couldn’t the second rule just be this?

'<controller:\w+>/<id:\d+>.*' => '<controller>/view',

I’m not sure whether it helps with your problem though.

Thanks for your Reply, and so close! With the .* it includes the period in the numeric integer so the parsing fails, but this works.

        '<controller:\w+>/<id:\d+>*' => '<controller>/view',

Which isn’t exactly valid regex I think? But I’m happy to have it work.