I would like to create a route that looks something like this:
routes.Add(new Route("{*url}/{action}.do/{id}", new MvcRouteHandler())
Is this possible? It seems like the catchall has to be last?
I would like to create a route that looks something like this:
routes.Add(new Route("{*url}/{action}.do/{id}", new MvcRouteHandler())
Is this possible? It seems like the catchall has to be last?
The catch-all has to be the last parameter in the route, as it says "match the entirety of what remains of the URL."
You could fake it, though, by having just the catchall and using a custom MyRouteHandler instead of the MvcRouteHandler. Your custom route handler would just manipulate the RouteContext to split the action and id back out of the URL before passing it to the MvcRouteHandler for processing.