5

I used the following line to emulate IE10 as IE7 in Windows 8 professional machine.

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

If I use this piece of code in a sample html, it worked fine and emulated as IE7. I observed value 7 using alert box to print : "document.documentMode".

But, if I use the same code in my project, it emulates as IE10 only. The value 10 has displayed in alert box.

There are no more meta tags except this. This code is working fine with IE7, IE8, IE9 which are emulated as IE7 only. Can any one tell me in which case it would fail to emulate.

Rajasekhar
  • 864
  • 4
  • 13
  • 25
  • 1
    [this? perhaps...](http://chentiangemalc.wordpress.com/2011/09/17/my-first-win8-ie10-app-compat-issue/) – Anirudh Ramanathan Oct 22 '12 at 14:51
  • have you tried using instead to see if this alternate mode works the way you expect it to? – Reid Johnson Apr 24 '13 at 15:57
  • 1
    @Reid Johnson, I tried that too. But, It didn't worked. – Rajasekhar Apr 30 '13 at 05:57
  • Can you give us the full header section, including the xml declaration if you are using the xhtml flavor of html, of both the working and non-working documents? It might help us to find some information, as from what I know, no browser setting will cause the x-ua-compatible meta tag not to trigger compatablity mode. Every time I have had this problem it is because of malformed html that disables the parsing of the meta tag. – Reid Johnson Apr 30 '13 at 13:48
  • If you are on an intranet, you get [overridden](http://stackoverflow.com/questions/2518256/override-intranet-compatibility-mode-ie8) by compatibility mode settings, meta tags be damned. Is something like that happening here? – brentonstrine Jun 27 '13 at 23:37

1 Answers1

0

I often have to test projects in IE 7–10 and have found the emulation meta tags to be very inconsistent.

I recommend downloading a free VM for each version of IE (7, 8, 9, and 10) from Microsoft's new modern.IE website. You can simply open each VM in Parallels, VMware, or VirtualBox and you'll immediately be in a clean version of Windows 7 with the appropriate version of IE installed for you.

Download VMs for any version of IE you require here: http://www.modern.ie/en-us/virtualization-tools#downloads

Bonus: They even give you a simple cURL command to download each VM. In your case, you can download a VM of Windows Vista with IE 7 installed with the following command:

curl -O "https://az412801.vo.msecnd.net/vhd/IEKitV1_Final/VMWare_Fusion/IE7_Vista/IE7.Vista.For.MacVMware.part0{1.sfx,2.rar,3.rar,4.rar}"
Graham Swan
  • 4,720
  • 2
  • 28
  • 38