In particular, my work site's home page is a Panel Page and it has a bunch of different styling. Right now the CSS is just included with the main theme style sheet.
Is there a way to say, "if this is node article, then add article.css"? Is CSS Injector what I'm looking for?
I might be interested in generalizing this to other nodes/sections/etc, but at the moment I just want to handle this one item.
What I ended up doing.
I'm using a bartik subtheme, and discovered in actually reading through template.php that there's some commented out code for including conditional style sheets. Code below did exactly what I needed:
if (drupal_is_front_page()) {
drupal_add_css(path_to_theme() . "/article.css", 'theme','all');
}
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.