Topic: multiple style sheets: bad idea?

right now I only have three style sheets default, accordion effect and slimbox. I'm wondering if there's any major reasons why I should avoid multiple sheets like I avoid classes > ids. it seems to me that multiple sheets have the benefit of being easier to organize but is there something I'm missing?

Vote up Vote down

Re: multiple style sheets: bad idea?

Nothing wrong with using multiple stylesheets.  But what do you mean you 'avoid classes > ids'?

Just because my computer is online does not mean that I am.
a&b WebDesign

Vote up Vote down

Re: multiple style sheets: bad idea?

thanks. You know next month I really should get a reference book. is there a thread with book recommendations?


Thelma wrote:

Nothing wrong with using multiple stylesheets.  But what do you mean you 'avoid classes > ids'?

i was referring to the sticky topic

Classes: Beginners always write classes, then you will see a dozen paragraphs with identical class names. Again this is due to this HTML style of writing we learned first and how we had to write fonts into everything. CSS is not that way.

Vote up Vote down

Re: multiple style sheets: bad idea?

Hi, in short, you should organize it the way that it is the easiest for you to maintain. Most only use one, but there are also quite a lot that use multiple.

Vote up Vote down

Re: multiple style sheets: bad idea?

A matter of choice really, as said what is better for you OR whoever will maintain it.

My issue with multiple style sheets is interfierence. It is easy to create elements that interfier with others on a different sheet.

As you write it it sounds like you have pre-made style sheets for scripts you are using, so that is fine.

I always use one.

However while working on a high level web application for the state, we used many. As I recall it, we had one for basic HTML tags, then we had one for specific items like forms, and ones for specific pieces of the application, one for ASP wizzards and one for the login section... This was the decision of the lead programmer. I hated it at first but although I was technically in charge of the look and feel as the only real web guy... each of 4 programmers made their own pages for their part. In the end multiple external just worked better.

So I would say the scope of the project is to be considered. Small projects I do not bother. But massive ones are likley easier with multiple. of course I would have a mobile style sheet separate from the general one.

Vote up Vote down

Re: multiple style sheets: bad idea?

What I sometimes do is create a 'default' style sheet for the site structure - the main blocks on the page.
Then another one to 'style' those blocks. Add images, colours, etc. to another CSS file. That lets me use and reuse the 'structure' andall of the 'style' information is adapted for the second site due to the separation of the CSS for the structure and the styling.

My signature goes here --> X

Vote up Vote down