ASP.NET App - Set IE7-Compatibility Mode?

2019-06-20 22:39发布

What is the simpliest way to set the IE7-Compatibility Mode mode in an ASP.NET application to deal with IE8 issues? Is it possible to set this via the web.config or must it either be set at the IIS or page level?

4条回答
forever°为你锁心
2楼-- · 2019-06-20 22:46

Instead of value="IE=EmultateIE7"

Replace with value="IE=EmulateIE7"

查看更多
放我归山
3楼-- · 2019-06-20 22:59

Add the header

X-UA-Compatible: IE=EmulateIE7

in the HTTP Headers tab of the site or application properties in IIS manager. In IIS7 its the HTTP Response Headers feature.

You can place it the <system.webServer> section of a web.config

   <httpProtocol>
        <customHeaders>
            <add name="X-UA-Compatible" value="IE=EmultateIE7" />
        </customHeaders>
    </httpProtocol>
查看更多
贪生不怕死
4楼-- · 2019-06-20 22:59
smile是对你的礼貌
5楼-- · 2019-06-20 23:05

If the solution posted here did not work for you, see my question and answer here ASP.NET Ignores IE7 Compatibility Mode Tag in Web.config

查看更多
登录 后发表回答