If you think about it, ordering IDs in the order that
they appear in the HTML goes against the grain of
XHTML/CSS separation of content and style.

If you change the position of an object in the HTML,
then you have to change it in the CSS, otherwise your
order becomes meaningless. The best way is to have an
order independent of the HTML content, such as
alphabetical.

--
Cameron Adams

W: www.themaninblue.com


--- Brian Duchek <[EMAIL PROTECTED]> wrote:

> I'm 100% with Andy on this one. My coding style (pun
> intended) usually
> falls into the source ordered approach (i.e. the ID
> selectors will be
> found in the CSS in the same order that they appear
> in the HTML
> document).
> 
> I'll do grouping of "helper" classes as well, as I
> use them as sort of
> utilities.
> 
> Within each class or selector statement, I'll let my
> editor (DW or
> Topstyle) place them for me.  At most it ends up
> being 10 short lines
> of text, and easy enough to scan quickly and
> identify what's what.
> 
> I do tend to put any hacks or "unusual approaches"
> at the bottom of
> the definition.
> 
> Cheers!
> Brian Duchek
> www.inquiline.com
> 
> 
> On Fri, 3 Sep 2004 10:33:23 +0100, Andy Budd
> <[EMAIL PROTECTED]> wrote:
> > Sean wrote:
> > 
> > > Does anyone know if there is a common way of
> listing styles in CSS? I
> > > don't mean the order of a:hover a: visited, or
> the order of
> > > specification. I am thinking more of some
> logical order that would be
> > > helpful to anyone else working on stylesheets I
> have created.
> > 
> > Are you meaning in a micro or macro sense. i.e.
> how to structure sets
> > of statement within a stylesheet or how to
> structure a set of
> > declarations within a statement?
> > 
> > If it's the former there tend to be a couple of
> main ways. One is to
> > group statements into logical types, such as all
> layout goes in one
> > place, all text stuff in another. However I
> personally break this info
> > into separate stylesheets as I find it easier to
> manage.
> > 
> > Another popular way is to structure stylesheets
> based on selector type,
> > so you may have all element selectors first, then
> all id's and lastly
> > all classes. I can see the logic behind this but
> it's not something I
> > favour.
> > 
> > The way I tend to arrange statements is by
> position in the flow of the
> > document. So I'll have all universal statements at
> the top, then
> > statements relating to the header, nav, content
> and finally footer
> > statements at the bottom. This works well for me,
> but I do often find
> > that I'll need to add a new statement later that's
> the same of similar
> > to one I already have. Rather than taking the
> original statement out
> > and putting it up top with the universal
> statements, I tend just to
> > tack a new selector on. This means that sometimes
> statements aren't
> > always exactly matching the flow of the document.
> This is fine if
> > you've only got one person working on the CSS, but
> would get confusing
> > if you've got multiple people using the same file.
> > 
> > As for arranging declarations within a statement,
> because statements
> > don't tend to be so long, I generally don't have a
> format. I simply put
> > them in the order I write them in.
> > 
> > Andy Budd
> > 
> > http://www.message.uk.com/
> > 
> > 
> > 
> >
>
******************************************************
> > The discussion list for 
> http://webstandardsgroup.org/
> > 
> > Proud presenters of Web Essentials 04
> http://we04.com/
> >  Web standards, accessibility, inspiration,
> knowledge
> > To be held in Sydney, September 30 and October 1,
> 2004
> > 
> >  See
> http://webstandardsgroup.org/mail/guidelines.cfm
> >  for some hints on posting to the list & getting
> help
> >
>
******************************************************
> > 
> > 
> 
> 
> 
> -- 
> Brian Duchek
> =-=-=-=-=-=-=-=
> e: [EMAIL PROTECTED]
> c: 847.809.2140
> w: www.inquiline.com
> =-=-=-=-=-=-=-=
>
******************************************************
> The discussion list for 
> http://webstandardsgroup.org/
> 
> Proud presenters of Web Essentials 04
> http://we04.com/
>  Web standards, accessibility, inspiration,
> knowledge
> To be held in Sydney, September 30 and October 1,
> 2004
> 
>  See
> http://webstandardsgroup.org/mail/guidelines.cfm
>  for some hints on posting to the list & getting
> help
>
******************************************************
> 
> 



        
                
__________________________________
Do you Yahoo!?
New and Improved Yahoo! Mail - 100MB free storage!
http://promotions.yahoo.com/new_mail 
******************************************************
The discussion list for  http://webstandardsgroup.org/

Proud presenters of Web Essentials 04 http://we04.com/
 Web standards, accessibility, inspiration, knowledge
To be held in Sydney, September 30 and October 1, 2004

 See http://webstandardsgroup.org/mail/guidelines.cfm
 for some hints on posting to the list & getting help
******************************************************

Reply via email to