MVC 3 Area route not working

前端 未结 8 779
有刺的猬
有刺的猬 2020-12-17 18:54

I created a Area in my MVC 3 application called \'Blog\'.

In global.asax I have the following code.

public static void RegisterRoutes(RouteCollection         


        
8条回答
  •  情深已故
    2020-12-17 19:17

    I'm using Phil Haack's routedebugger to troubleshoot problems such as this one. It conveniently shows all registered routes and how the entered URL matches your configuration.

    It works by overriding the regular application flow, which you enable by adding this line at the end of Application_Start:

    RouteDebug.RouteDebugger.RewriteRoutesForTesting( RouteTable.Routes );
    

提交回复
热议问题