CSS 3 Module <== Test # ==>
W3C Selectors 38 of 153 of the static tests category
Testing Date Revision
:first-child pseudo-class (ID #32) 2004-03-03 1.0
green cell 1.2 1.3
green cell 2.2 2.3
green cell 3.2 3.3

This paragraph contains some text and a span that should have a green background

.red { background-color : red }
.t1 td:first-child { background-color : lime }
p > *:first-child { background-color : lime }
<div>
<table class="t1" border="1">
  <tr>
    <td class="red">green cell</td>
    <td>1.2</td>
    <td>1.3</td>
  </tr>
  <tr>
    <td class="red">green cell</td>
    <td>2.2</td>
    <td>2.3</td>
  </tr>
  <tr>
    <td class="red">green cell</td>
    <td>3.2</td>
    <td>3.3</td>
  </tr>
</table>
</div>
<p>This paragraph contains some text
          <span>and a span that should have a green background</span>
</p>