Routing problem


Hi All

I have two pages used same page type, the url like following

1. http://website/en/{node}/GUID

2. http://website/client/en/{node}/GUID (By the way, the 'client' will change for different language)

I created a router like this {language}/{node}/{id}/{action},

but only link 1 works, link 2 is 404.

How could I let link2 work?

I used EPI 8.*

Jun 24, 2015 12:18

This is only about MVC route mapping. You should create another route for link 2 before your current mapped route for link 1. If "client" is dynamic also, then you could have something

routes.MapRoute("link2", "{client}/{language}/{node}/{id}/{action},...);
route.MapRoute("link1", "{language}/{node}/{id}/{action},...);

So when navigate to link 2, first route will be mapped. when navigate to link 1, first route is not match, then second route is mapped.

Hope this helps

Jul 22, 2015 11:07
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.