* is the unversal selector. That means it matches all elements. And
that means all elements (including html, head, body etc)
#foo * selects any element which is a descendant of #foo.
>my guess is that the double asterisk is a typo or misunderstanding of
>css selectors.
No.
It's a common trick to get round the lack of support in IE6 and under
for the child selector > (ie. it is a direct descendant of the
element)
So instead of
#mainNav > * {
padding-left: 20px;
}
we use
#mainNav * {
padding-left: 20px;
padding-right: 20px;
}
#mainNav * * {
padding-left: 0;
}
since * * matches elements which are descendants of the first
element's children.
This is nice since * has no specificity, so it shouldn't override
other values that have been set with explicit selectors.
But note, there are flipsides.
One is that you must have the * * declaration after the * one because
they have the same specificity. Not that that's much of a flipside ;)
The other is more serious
http://meyerweb.com/eric/thoughts/2005/05/31/universal-child-replacement/#comment-5719
Namely that you may override elements which have been specified using
a lower specificity elsewhere.
______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/