hi,

is there a mechanism to use css tags sidewide.
I think of something like placing a style.css in my sites/ directory.
Or do i have to edit the style.css file of every theme.

Angel

Comments

jswaby’s picture

not that I know of..

but what you could do is create a module, and specify that the module needs a CSS file. This CSS file is included regardless of what theme you're using.

1st-angel’s picture

thanks,
i think i will do it this way. This is, IMHO, cleaner than editing the core themes.
thanks

1st-angel’s picture

thanks,
i think i will do it this way. This is, IMHO, cleaner than editing the core themes.
thanks
(sorry for the double posting)

nancydru’s picture

How about a block that does a drupal_add_css? You can style it to be hidden.

If you create a module, that CSS will be included BEFORE the theme's CSS. May not be what you want.

EDIT: Just tried <?php drupal_add_css("sites/default/mystyle.css"); ?> in a php block with a -10 weight in the left sidebar. It does not show up on the rendered page (so no hiding needed), but my CSS is included in the source - but before the theme CSS.

Nancy W.
now running 5 sites on Drupal so far
Drupal Cookbook (for New Drupallers)
Adding Hidden Design or How To notes in Your Database

1st-angel’s picture

that sounds very good. I think i will give it a try.
Thank you all.

nancydru’s picture

With that order, it may not do you much good. It will not override anything in the theme's CSS.

Nancy W.
now running 5 sites on Drupal so far
Drupal Cookbook (for New Drupallers)
Adding Hidden Design or How To notes in Your Database

nancydru’s picture

I've actually been thinking about doing this:

Create your own separate CSS and then include it in every style sheet. It still means some editing, but you know where to find your stuff, and it's easier to change versions.

@import url(/sites/all/themes/mystyles.css);

EDIT: I like the above ideas better.

Nancy W.
now running 5 sites on Drupal so far
Drupal Cookbook (for New Drupallers)
Adding Hidden Design or How To notes in Your Database