开发者

Route controller to Foo/{Action}

I开发者_如何学C was wondering if there is some easy way to route an entire controller to something like:

Foo/{Action}?

or do I have to write a route for every action in that controller?

/M


Not totally sure what you want todo, but how about:

            routes.MapRoute(
            "FooMap",
            "Foo/{action}",
            new { controller = "Foo"})
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜