Why does IE9 switch to compatibility mode on my website?

Works in IE9 documentMode for me. Without a X-UA-Compatible header/meta to set an explicit documentMode, you’ll get a mode based on: whether the user has clicked the ‘compatibility view’ button in that domain before; perhaps also whether this has happened automatically due to some other content on the site causing IE8/9’s renderer to crash and … Read more

Override intranet compatibility mode IE8

It is possible to override the compatibility mode in intranet. For IIS, just add the below code to the web.config. Worked for me with IE9. <system.webServer> <httpProtocol> <customHeaders> <clear /> <add name=”X-UA-Compatible” value=”IE=edge” /> </customHeaders> </httpProtocol> </system.webServer> Equivalent for Apache: Header set X-UA-Compatible: IE=Edge And for nginx: add_header “X-UA-Compatible” “IE=Edge”; And for express.js: res.set(‘X-UA-Compatible’, ‘IE=Edge’)

tech