2011-10-12 46 views

回答

2

默认页面设置与另一个版本的IIS版本有所不同。

如果你有IIS7或IIS表达然后在web.config文件中以下条目添加

<system.webServer> 
    <defaultDocument> 
     <files> 
     <clear/> 
     <add value="MasterFile.aspx"/> 
     </files> 
    </defaultDocument> 
</system.webServer> 

或者你可以使用urlMappings,

<system.web> 
    .... 
    <urlMappings> 
     <add url="~/Default.aspx" mappedUrl="~/MasterFile.aspx"/> 
    </urlMappings> 
</system.web> 

Setting Up Default Documents (IIS 6.0)

1

Plus来注释以上,当您在IIS上部署时,将默认文档名称设置为MasterFile.aspx中的虚拟目录或应用程序配置,并且页面也会在您加载时sers只在浏览器中有应用程序url。