I’ve been having this problem serveral times, so now I’ve decided to make a workaround, but before I do so, and post a workaround, I would like to hear you opinion. There might be some way to do this.
Because I base a lot of my business on SEO, I often have to have two different controller actions with the same url. A real life example is a webshop with products and possibility to tag products. For each tag there is a page describing the tag and links to products in it. A tag’s url rule should be “’/<slug>’ => ‘tag/show’” and a product’s url should be “’/<slug>’ => ‘product/show’”. The problem is clear; I cant have both.
The temporary fix is something like:
'/<ProductSlug>' => 'product/show' '/<tagSlug>' => 'tag/show'
And then in "product/show" forward to "tag/show" if no product was found for that url.
Have you ever had this problem? How did you solve it?