order in which css code is placed

L

Leslie

When writing css code, either in an external stylesheet, or in the
head of the document, does it make a difference what order the code is
placed on the page?

It makes sense to me to put the code in the order in which it will be
used on the .html page, but I got to wondering tonight if it really
makes a difference in how the pages loads and/or displays.

Just curious......

Thanks,

Leslie
"I refuse to have a battle of wits with an unarmed person."
 
B

brucie

..and where cascading is not an issue, I always write alphabetically
so modification is easier.

i write as the rules appear in the page so i know if a class is at the
bottom of my css its used near the bottom of the html page somewhere or
vice versa. very hand when you come back to a page 12 months later. i
also usually use separate files for styles and colors. makes changing
colors a lot easier.
 
T

Toby A Inkster

brucie said:
i write as the rules appear in the page so i know if a class is at the
bottom of my css its used near the bottom of the html page somewhere or
vice versa.

Ditto, although for a lot of inline styles, they may be used several
times or not at all on a page and scattered around in lots of places.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,576
Members
45,054
Latest member
LucyCarper

Latest Threads

Top