Question

I created a sub theme which is intended to just have a few color changes and background image changes.

The Base theme is called limon. The sub theme is limon_orange. In the sub theme, i have a unique style sheet that I want to use to override the base theme styles via cascade. In the limon_orange.info file I have this line:

stylesheets[all][] = orange.css

The sub theme works, but orange.css is never used. What am I missing? Why is orange.css not loading?

Was it helpful?

Solution

Any change in .info does not take effect only by clearing cache. Remember to clear the theme registry. You can do this by just going to the admin/appearance and saving it.

OTHER TIPS

First, I assume that you do not need a relative path for the stylesheet and Drupal can find the file.

There is a strong chance that your css is being read but is overridden by other style elements. If you use firebug you can see which css files and style inputs are controlling the display. Quite often you might have an element such as a paragraph, header, or link that is attached to several classes. CSS uses a scoring system to determine what style will prevail. The css hierarchy is scored with css info in a 'style' definition highest:

style="" -       1000 points
#Wrapper #ID {} - 200 points
#ID .class {} -   110
div#id {} -       101 
#id -             100
p.class class {}   21
p.class {} -       11
div p {} -          2
p -                 1

(p represents any html type such as h1, a, etc.)

Licensed under: CC-BY-SA with attribution
Not affiliated with drupal.stackexchange
scroll top