Blog
Getting Rid of the @#*%! IE8 Compatibility Button
I had thought that ensuring a Web page was 100% standards-compliant was the way to get rid of the compatibility button that IE8 displays to help you view pages that looked fine in IE7 but don't look so good in its (presumably more exacting) successor, IE8.
Supposedly this button was a sort of work-around, allowing Microsoft to come out with a truly standards-compliant browser without requiring nearly every Web site manager in the world to patch up their site to make sure it still looks OK in this new IE version. There is already more than enough that's been written about whether this was a good idea, so I'm not going to comment on that here. Rather, I simply want to pass on some information on how to make the button go away when you don't want it there.
It's really rather simple: You need to add a meta tag that says
<meta http-equiv="X-UA-Compatible" content="IE=8">
Or, if your page only works with compatibility mode switched on, use
<meta http-equiv="X-UA-Compatible" content="IE=7">
instead.
But there's one catch, a detail I didn't find anywhere searching on blogs and user groups but rather, happened upon accidentally: The meta tag has to appear before any script or style tags that link in external resources.
Or at any rate, this was my conclusion as to how things work from admittedly limited empirical evidence. If you happen across contrary evidence or reach a different conclusion, please let me know.



Comments
Post new comment