开发者

Default.aspx page in asp.net MVC

What is the Default.aspx page for in an MVC app? Does this actually execute? Does this开发者_开发知识库 page have anything to do with the "Default" route in the global.asax?


If you take a look at the comments at the top of Default.aspx

Please do not delete this file. It is used to ensure that ASP.NET MVC is activated by IIS when a user makes a "/" request to the server.

Basically, it acts as an override for the possibility of a different default page being loaded by IIS. In IIS6 if you have an index.html in the same directory as your MVC application, it can sometimes render that file instead of looking for the default blank route in your application. Default.aspx prevents that from happening.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜