jump to navigation

Set IE7 Compatibility Flag for IE8 in IIS May 11, 2009

Posted by codinglifestyle in IIS.
trackback

Now that IE8 has officially been pushed out via Windows Update it’s time to get serious about testing your web site compatibility.  As you probably know, one of the big changes in IE8 is complying to standards for increased interoperability.  In other words, Microsoft won’t be going it’s own way with standards anymore.  Out of the box, IE8 complies with standards that many pages developed with IE6 or IE7 in mind won’t adhere to.  This means customers may have serious layout and style issues when their customers start browsing with IE8.

There is a meta flag that can be set set to tell IE8 to automatically switch to compatiblity view, which will render the page the same as IE7.  This is fine if you have a masterpage, but in an older app with many pages this is not ideal.  Luckily, there is a dead easy way of setting a custom HTTP header which will tell IE8 the same thing.

IE7Compat

 

  1. Open iismgr
  2. Open website properties
  3. Click HTTP Headers tab
  4. Click Add
  5. For customer header name enter X-UA-Compatible
  6. For custom header value enter IE=EmulateIE7
  7. Click OK

Done!  From now on IE8 browsers will default to compatibility mode and won’t even offer the user the option of viewing the side with compatibility mode off.

Comments»

1. rashipsaiyed - January 12, 2012

if Issue is in single page just place this tag in ur page header

If in entire application just add what is shown above


Leave a comment