W3C home > Mailing lists > Public > www-style@w3.org > February 2005

[CSS3] nth-child pseudo class #2

From: Andrew Fedoniouk <news@terrainformatica.com>
Date: Sat, 5 Feb 2005 18:41:13 -0800
Message-ID: <003f01c50bf5$53276170$0c01a8c0@TERRA>
To: <www-style@w3.org>

Quote from [1]

<quote>
If b=0, then every a-th element is picked:
tr:nth-child(2n) /* represents every even row of a HTML table */
</quote>

Question is: what does "even" mean here? And "every a-th element" also is 
not clear at all.Is first child even or odd?Following the rule: "The 
:nth-child(an+b) pseudo-class notation represents an element that has an+b-1 
siblings before it"and assuming that tr:nth-child(2n) == tr:nth-child(2n + 
0)first element should not match tr:nth-child(2n)Am I right?And also phrase 
"The a and b values must be zero, negative integers or positive integers." 
[1]should be written just as "The a and b values must be integers". This is 
more precise.[1] 
http://www.w3.org/TR/2001/CR-css3-selectors-20011113/#nth-child-pseudoThanks 
in advance,Andrew Fedoniouk.http://terrainformatica.com 
Received on Sunday, 6 February 2005 02:39:17 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:54:35 GMT