Re: [css3-selectors] How do *-of-type selectors define the type?

L. David Baron wrote:
> After reading the text:
>   # The :nth-of-type(an+b) pseudo-class notation represents an
>   # element that has an+b-1 siblings with the same element name
>   # before it in the document tree,
> in
> it is not clear to me what "the same element name" means.
> defines
> three types of names.  Given the element:
>   <html:p xmlns:html="" />
> these names are:
>   expanded name:  the pair of strings ("", "p")
>   local name:     the string "p"
>   qualified name: the string "html:p"
> css3-selectors should define which of these three names are referred
> to by the definitions of :nth-of-type() and :nth-last-of-type() (and
> thus, by reference, :first-of-type, :last-of-type, and
> :only-of-type).
> I strongly prefer that it is the expanded name that matches.
> I wrote a testcase at
> .  The only
> implementation I could find that produced sensible results (Opera
> 9.5 beta) uses the expanded name (but doesn't support xmlns="").
> Konqueror 3.5.9 seems to parse the testcase as HTML instead of
> XHTML, and Safari 3.0.4 fails the control test and matches item (2)
> (along with (1), (4), and (5)).

Fixed by using the term "expanded name" instead of "name".


Received on Thursday, 16 October 2008 11:49:53 UTC