I'm adding one new route to RouteCollection
like this:
我正在向RouteCollection添加一条新路由,如下所示:
routes.Add(new Route("{*data}", new MyRoutehandler()));
How can I specify the controller name and action name inside this MyRouteHandler
(my own route handler)?
如何在MyRouteHandler(我自己的路由处理程序)中指定控制器名称和操作名称?
1 个解决方案
#1
Take a look here:
看看这里:
- Custom routing for ASP.NET MVC
- ASP.Net MVC Framework - Create your own IRouteHandler
- ASP.Net MVC Framework - Creating a IRouteHandler which will support Interceptors
- ASP.NET MVC tips: Routing Engine to aid SEO / 301 Redirect / Tracking
ASP.NET MVC的自定义路由
ASP.Net MVC框架 - 创建自己的IRouteHandler
ASP.Net MVC框架 - 创建一个支持拦截器的IRouteHandler
ASP.NET MVC技巧:路由引擎,以帮助SEO / 301重定向/跟踪
#1
Take a look here:
看看这里:
- Custom routing for ASP.NET MVC
- ASP.Net MVC Framework - Create your own IRouteHandler
- ASP.Net MVC Framework - Creating a IRouteHandler which will support Interceptors
- ASP.NET MVC tips: Routing Engine to aid SEO / 301 Redirect / Tracking
ASP.NET MVC的自定义路由
ASP.Net MVC框架 - 创建自己的IRouteHandler
ASP.Net MVC框架 - 创建一个支持拦截器的IRouteHandler
ASP.NET MVC技巧:路由引擎,以帮助SEO / 301重定向/跟踪