Courtesy of SelectORacle (http://penguin.theopalgroup.com/cgi-bin/
css3explainer/selectoracle.py):

        * + html *.Selector1 *.Selector2, * + html *.Selector3
*.Selector4
        Selects any element with a class attribute that contains the
word Selector2
              that is a descendant of any element with a class
attribute that contains the word Selector1
                  that is a descendant of a html element that
immediately follows any element
    OR
        any element with a class attribute that contains the word
Selector4
            that is a descendant of any element with a class attribute
that contains the word Selector3
                that is a descendant of a html element that
immediately follows any element.

The only reason for using the *+html is to hide the rule from ie5 -
ie6 (they don't support the '+' in rules)

The comma indicate alternatives. So, rewriting the rule as "*
+html .Selector1 .Selector2 .Selector3 .Selector4" will give you a
different result as it describes one condition, not two. Specifically,
it describes:
    a Selector4 inside a Selector3 inside a Selector2, inside a
Selector1 inside an HTML tag
where as the original form describes either
    a Selector4 inside a Selector3 inside a HTML tag
    OR
    a Selector2, inside a Selector1 inside an HTML tag


On Feb 11, 5:16 am, gpadu99 <[email protected]> wrote:
> Can somebody explain to me what is this:
>
> *+html .Selector1 .Selector2,
> *+html .Selector3 .Selector4
> {
>         background-image: url('anImage.gif');
>
> }
>
> what does the "*+html" symbol means? Also why is there a comma in the
> first line? I mean, would it be the same if we write:
>
> *+html .Selector1 .Selector2 .Selector3 .Selector4
> {
>         background-image: url('anImage.gif');
>
>
>
> }

-- 
--
You received this because you are subscribed to the "Design the Web with CSS" 
at Google groups.
To post: [email protected]
To unsubscribe: [email protected]

Reply via email to