LinuxUK
   Home About us Design services Get in Touch Testimonails Create and account / Log in
Categories
 Templates

 Security checks

 Support Club

 Tips and Tricks

 How to guides osC

 My Contributions

 osCommerce versions

 Base64 Decoder

 Link to us!

Make IE8 emulate IE7 in php
Product stats Product Stats
Products name Product Name: Make IE8 emulate IE7 in php
Products info Product description

 So you have a great site, but does not render well in IE 8.

If it then works in compatibility mode, you need to make changes to your site.
If you need to make site wide changes the best way wold be to make an addition to your HTACCSSS file.

Add this to your htaccess

 

<FilesMatch ".(php)$">
Header set X-UA-Compatible "IE=7"
</FilesMatch>

or

 

<FilesMatch ".(php)$">
Header set X-UA-Compatible "IE=EmulateIE7"
</FilesMatch>

the first runs in Quirks mode, the second emulates

 

If you want to effect a single page only add this line at the top of your file, in the opening <?php tag
  if (strpos($_SERVER['HTTP_USER_AGENT'],"MSIE 8")) {header("X-UA-Compatible: IE=7");}

 

  if (strpos($_SERVER['HTTP_USER_AGENT'],"MSIE 8")) {header("X-UA-Compatible: IE=EmulateIE7");}

again the differences are Quirks and Emulate mode.

You may find you need to add a style definition to your <div id=" tags as this will effect your stylesheet output.

Here is a link that explains to you the differences

 

 

 

Reviews

Make IE8 emulate IE7 in php - TITLE_DEL_ICIO_US Make IE8 emulate IE7 in php - TITLE_DIGG Make IE8 emulate IE7 in php - TITLE_YAHOO_MYWEB Make IE8 emulate IE7 in php - TITLE_SPURL Make IE8 emulate IE7 in php - TITLE_FURL Make IE8 emulate IE7 in php - TITLE_ASK Make IE8 emulate IE7 in php - TITLE_SQIDOO Make IE8 emulate IE7 in php - TITLE_SIMPY Make IE8 emulate IE7 in php - TITLE_REDDIT Make IE8 emulate IE7 in php - TITLE_MA_GNOLIA Make IE8 emulate IE7 in php - TITLE_FACEBOOK_BOOKMARK Make IE8 emulate IE7 in php - TITLE_GOOGLE_BOOKMARK