3

Now that IE9 has come out, I noticed that the IE=EmulateIE7 trick also affects it. How can I make it target IE8 only??

So far I tried conditional comments

<!--[if IE 8]>
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" >
 <![endif]-->

But for some reason it does not work (maybe conditional comments dont work with meta tags?). Anyone have any idea?

agente_secreto
  • 7,959
  • 16
  • 57
  • 83

2 Answers2

3

Use the dual mode:

<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7, IE=EmulateIE9">

as mentioned here: Emulate IE7 for IE8 but not for IE9 using "X-UA-Compatible"

Community
  • 1
  • 1
meo
  • 30,872
  • 17
  • 87
  • 123
3

I've read that using a semi-colon as the separator doesn't work, and that you should use commas instead, i.e:

content="IE=EmulateIE7, IE=EmulateIE9"

and NOT:

content="IE=EmulateIE7; IE=EmulateIE9"

Dan
  • 31
  • 2
  • Can I use httpd.conf for dual mode. Right now I use like Header add X-UA-Compatible IE=EmulateIE7 Pl. check the question I have asked http://stackoverflow.com/questions/13189817/how-do-i-set-different-options-for-x-ua-compatible-in-apache-for-ie8-and-ie9 – ppant Nov 02 '12 at 09:11