<?xml-stylesheet href="../../../style/xml-full.css" type="text/css"?>
<?xml-stylesheet href="css3-modsel-30.css" type="text/css"?>
<test xmlns:xlink="http://www.w3.org/1999/xlink">
 <title>:nth-of-type() pseudo-class</title>
 <author>Daniel Glazman</author>
 <metadata>
  <item> <name>CSS 3 Module</name> <data>W3C Selectors</data> </item>
  <item> <name>Next</name> <data xlink:type="simple" xlink:href="css3-modsel-31.xml">:nth-last-of-type() pseudo-class</data> </item>
  <item> <name>Previous</name> <data xlink:type="simple" xlink:href="css3-modsel-29b.xml">:nth-last-child() pseudo-class</data> </item>
  <item> <name>Test #</name> <data>29 of 224 of the static tests category</data> </item>
  <item> <name>Testing</name> <data>:nth-of-type() pseudo-class</data> </item>
  <item> <name>ID</name> <data>30</data> </item>
  <item> <name>Date</name> <data>11-july-2001</data> </item>
  <item> <name>Revision</name> <data>1.0</data> </item>
 </metadata>
  <content xmlns:a="http://www.example.org/a" xmlns:b="http://www.example.org/b" xmlns:html="http://www.w3.org/1999/xhtml">
<p xmlns="http://www.w3.org/1999/xhtml">This paragraph is here only to fill space in the DOM</p>
<address xmlns="http://www.w3.org/1999/xhtml">And this address too..</address>
<p xmlns="http://www.w3.org/1999/xhtml">So does this paragraph !</p>
<p xmlns="http://www.w3.org/1999/xhtml" class="red">But this one should have green background</p>
<dl xmlns="http://www.w3.org/1999/xhtml">
  <dt class="red">First definition term that should have green background</dt>
    <dd class="red">First definition that should have green background</dd>
  <dt>Second definition term</dt>
    <dd>Second definition</dd>
  <dt>Third definition term</dt>
    <dd>Third definition</dd>
  <dt class="red">Fourth definition term that should have green background</dt>
    <dd class="red">Fourth definition that should have green background</dd>
  <dt>Fifth definition term</dt>
    <dd>Fifth definition</dd>
  <dt>Sixth definition term</dt>
    <dd>Sixth definition</dd>
</dl>
</content>
  <source>
   <css>.red { background-color : red }
p:nth-of-type(3) { background-color : lime }
dl &gt; :nth-of-type(3n+1) { background-color : lime }
</css>
   <xml>
&lt;p xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;This paragraph is here only to fill space in the DOM&lt;/p&gt;
&lt;address xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;And this address too..&lt;/address&gt;
&lt;p xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;So does this paragraph !&lt;/p&gt;
&lt;p xmlns=&quot;http://www.w3.org/1999/xhtml&quot; class=&quot;red&quot;&gt;But this one should have green background&lt;/p&gt;
&lt;dl xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;
  &lt;dt class=&quot;red&quot;&gt;First definition term that should have green background&lt;/dt&gt;
    &lt;dd class=&quot;red&quot;&gt;First definition that should have green background&lt;/dd&gt;
  &lt;dt&gt;Second definition term&lt;/dt&gt;
    &lt;dd&gt;Second definition&lt;/dd&gt;
  &lt;dt&gt;Third definition term&lt;/dt&gt;
    &lt;dd&gt;Third definition&lt;/dd&gt;
  &lt;dt class=&quot;red&quot;&gt;Fourth definition term that should have green background&lt;/dt&gt;
    &lt;dd class=&quot;red&quot;&gt;Fourth definition that should have green background&lt;/dd&gt;
  &lt;dt&gt;Fifth definition term&lt;/dt&gt;
    &lt;dd&gt;Fifth definition&lt;/dd&gt;
  &lt;dt&gt;Sixth definition term&lt;/dt&gt;
    &lt;dd&gt;Sixth definition&lt;/dd&gt;
&lt;/dl&gt;
</xml>
  </source>
</test>