2010-11-29 43 views
0

From; ASP.NET Ignores IE7 Compatibility Mode Tag in Web.configIIS6忽略Web.config中的IE7兼容模式標記

<system.web> 
    <httpProtocol> 
     <customHeaders> 
     <clear /> 
     <add name="X-UA-Compatible" value="IE=EmulateIE7" /> 
     </customHeaders> 
    </httpProtocol> 
</system.web> 

相關問題Chris Shouts補充說,

當我嘗試將<httpProtocols>節添加到<system.web>我得到

Parser Error Message: Unrecognized configuration section system.web/httpProtocol. 

任何提示嗎? 我非常需要能夠通過IIS6 web.config中添加customHeaders(我不過我假設這是不行的)

感謝

+0

請仔細閱讀該討論。如果您使用IIS 6,則web.config無法實現此目標。 – 2010-11-29 02:02:10

回答

0

你不小心在你的web.config 2個<system.web>板塊?

2

它應該<system.webServer>而不是<system.web>

+0

從原帖'IIS6看在Web.config的部分,而不是部分' – Thermionix 2010-11-29 03:12:34