开发者

asp.net mvc url routing to /Folder/Folder/Setup.exe?

can I use ASP.NET MVC URL like this witout redirect to it from Global.asax?:

http://test.com/product/versions/0.9开发者_高级运维/Setup.exe

is this case products is Controller and /versions/0.9/Setup.exe just a /folder/folder/Setup.exe

how it should be in my controller? without action.. or?


You can ignore routes for a specific extension: Make routing ignore requests for a file extension

Something like this:

routes.IgnoreRoute("{*setupfiles}", new {setupfiles=@"(.*/)?.exe(/.*)?"});
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜