Rectangle 27 0

c Routing to virtual item?


MapPageRoute
routes.MapPageRoute("SalesRoute",
    "SalesReport/{locale}/{year}",
    "~/sales.aspx");

Also, RouteExistingFiles should probably be false. You are trying to route things that don't exist as files. If you set RouteExistingFiles = true then the default handling for files that exist will NOT be used when a route matches. All you want to do is deal with paths that don't exist, but represent content from a database, right? So leave this false.

In order to route to an extensionless target like /content/something you need to use Integrated Mode in the IIS application pool. If you cannot change this, then there's no easy way to do what you want, other than setting up a custom 404 handler, and manually dealing with the URL from there. This is probably the cause of your 404 errors.

That would cause matching routes to invoke sales.aspx in response. In your example, the target is ~/about/company which looks like a route, not an actual target - your actual target that handles the CMS request should have an aspx extension.

Note