[thelist] CSS help

Jackson Yee jyee at vt.edu
Fri Feb 21 19:02:01 CST 2003


"Michael Robertson" <mike at mikeemedia.com> wrote in message
news:020801c2d9df$c4d59020$6500a8c0 at ben...
> Another question: is it better to have a single .css file in a site with
500
> rules or 10 files with 50 rules?

That depends on what you're doing with your site.  One of the main reasons
why CSS is so attractive is that you can download a CSS file once, and never
do it again; thus saving you the agony of <font>, bgcolor="", and all of
those html decorative declarations.  If you're using every style in the file
on every page, then definitely keep it in one file.  If some rules apply to
only a specific section, use separate files.

I myself tend to divide CSS files by function rather than rules, so my
picture gallery gets one file, my calendar gets one file, and my main site
get one file.  Your mileage may vary though.

--
Regards,
Jackson Yee
jyee at vt.edu





More information about the thelist mailing list