• Skip to primary navigation
  • Skip to main content

Void Zone Media

Just a test site till I decide to do something with it.

  • Void Zone Media
  • Archive
  • Projects

Thesis 1.x – IE8 – Remove IE7 Emulation

May 8, 2012 by Tim Milligan

I’ve posted this solution numerous times on the forums before so it’s probably high time I post it here…

A lot of you may have run into (repeated) issues with IE8 where it doesn’t render Thesis sites properly.  9 times out of 10 that’s because Thesis is telling IE8 to render the site as if it’s IE7.  This causes a whole slew of issue from css clears not being effective to z-indexes not functioning properly etc.

Fortunately, it’s a very easy problem to solve on your own (as we wait for them to remove the emulation from Thesis’ base code)

Add the following to your custom_functions.php and voila, problem(s) solved.

function remove_ie7_emulation() {
    $browser = $_SERVER['HTTP_USER_AGENT'];

    if (preg_match("/MSIE 8.0/", $browser) && !is_admin())
        header('X-UA-Compatible: IE=8');
}
add_action('init','remove_ie7_emulation');

Filed Under: Solutions

Reader Interactions

Comments

  1. Darcy says

    July 5, 2012 at 12:30 am

    So awesome. Thanks a million billion!

  2. Tim Milligan says

    July 6, 2012 at 2:32 pm

    You’re welcome.

Copyright © 2023 · Genesis Sample on Genesis Framework · WordPress · Log in