Weird problem in IE8
-
I just finished a site for a client. They are still using IE8. I noticed that my conditional IE CSS call to its stylesheet was displaying as code above the site. There are several people administering the site and this did not display consistently across all of their computers.
URL is http://www.stratfordvna.org/
Here is a screenshot from netrenderer.com. The code only appears under IE8 and disappears under IE7 and all later versions. Some people have told me that when they test it in IE8 they don’t see the code. It was clearly visible on my client’s computer.
Here is the code I use for my IE conditional CSS tags in functions.php:
// IE conditional wrapper add_filter( 'style_loader_tag', 'mark_ie_conditional', 10, 2 ); function mark_ie_conditional( $tag, $handle ) { if ( 'theme-ie7-only' == $handle ) { $tag = '<!--[if lte IE 7]>' . "\n" . $tag . '<![endif]-->' . "\n"; } else if ( 'theme-ie8-only' == $handle ) { $tag = '<!--[if lte IE 8]>' . "\n" . $tag . '<![endif]-->' . "\n"; }else { } return $tag; }
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
The topic ‘Weird problem in IE8’ is closed to new replies.