_s Underscores theme conditional stylesheet
-
I have a site built with the Underscores theme where there are 2 background images. IE8 and below don’t like this, so I’ve added a conditional stylesheet. Despite having done this on other sites, I cannot get this one to read properly. This theme’s regular stylesheet is enqueued in the functions file. I have tried adding it the conventional way in the header:
<!--[if lte IE 8]> <link rel="stylesheet" href="<?php bloginfo('template_directory'); ?>/ie.css "media="screen" type="text/css"/> <![endif]-->
The path shows up correctly, but I don’s see any of the style changes taking effect.
I’ve also tried to enqueue it in the functions file:
{ global $wp_styles; // other style sheets... // ie-only style sheets wp_register_style('ie', get_bloginfo('template_directory') . '/ie.css'); $wp_styles->add_data('ie', 'conditional', 'lte IE 8'); wp_enqueue_style('ie'); }
This pulls a stylesheet in the wp-admin folder! Not what I’m looking for either. I feel like I’m missing something simple. Any help appreciated!
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘_s Underscores theme conditional stylesheet’ is closed to new replies.