As I understand the OOCSS philosophy, links in the head should have
their own class as should links in the footer. A key idea behind OOCSS
as a philosophy (as I have understood it) is that an object (link, box,
whatever) could be placed anywhere and maintain its style.
In addition this selector is not desired from a performance perspective.
Selectors are applied form right to left. So, when finding what elements
to apply this style to, the browser will first find all a tags, then
find a tags that are inside a .head, walking every parent element of
every a to discover if it is inside of a .head.
Now, I still have some of this in my CSS I admit. I am working on
getting it all out of there.
A better solution may be:
<a class="head button">
a.head { /* set default styles for links in header */ }
It does lead to a bit more text in the document, but it is much more
controllable.
Brian.
http://brian.moonspot.net
> --
> You received this message because you are subscribed to the Google
> Groups "Object Oriented CSS" group.
> To post to this group, send email to object-or...@googlegroups.com.
> To unsubscribe from this group, send email to
> object-oriented...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/object-oriented-css?hl=en.
Dave.