X-UA compatible in JavaScript and CSS files

For compatibility with IE8, we have added a header X-UA-Compatible: IE=EmulateIE7

to the list of IIS response headers.

For some reason, these headers are sent for ASPX etc, but not for static files - JS / CSS.

Does this header have anything to do with JS / CSS content that is related to HTML content? My guess is that as long as the resulting HTML has a response header along with it, IE8 should respect that header and render content based on EmulateIE7 compatibility mode. Is this the case?

+1


a source to share


2 answers


Does this header have anything to do with JS / CSS content that is related to HTML content?



no, you just need to send the header with the HTML file. The browser then switches to backward compatibility mode and considers all associated "ie7 path" resources.

+2


a source


Have you considered upgrading your code to standards and then applying IE7 fixes like IE8-js ? Typing this title simply says that "this site is broken by design" which won't help you with other browsers or future versions of IE.



+2


a source







All Articles