ASP.NET MVC: How to Route Search Term with . (Period) at the end

后端 未结 2 1724
暗喜
暗喜 2020-12-01 21:05

I get a 404 response from .Net MVC when I try to make a request where my search term ends with a . (period). This is the route that I\'m using:

         


        
2条回答
  •  情歌与酒
    2020-12-01 22:04

    If you are using .NET 4.0, you can set this flag in the system.web section of your web.config and it will be allowed:

    
    

    I've tested it and it works. Haack has an explanation of it.

提交回复
热议问题