Posted By

Daidaros on 12/18/09


Tagged

lists ul li


Versions (?)

Select just first list item


 / Published in: CSS
 

Painting the first item fuchsia and the rest black.

  1. ul li:first-child {
  2. color: fuchsia;
  3. }
  4.  
  5. ul li:first-child * {
  6. color: black;
  7. }
  8.  
  9. ul li ul li:first-child {
  10. color: black;
  11. }

Report this snippet  

You need to login to post a comment.