Test of CSS2 :first-child

The styles in this document are the following:

BODY	{color: black; background: white; }
P:first-child	{color: green; background: white; }
DIV.two > *:first-child	{color: purple; background: white; }
DIV.three *:first-child {color: blue; background: white; }

This should be green.

This should be black.

This should be black.

This should be black.

This should be purple.

This should be black.

This should be purple.

This should be black.

This should be blue.

The first few words of this paragraph should be blue, but the rest should be black.

This should be black, but the emphasized text should be blue.


Valid HTML 4.0!

(Back to CSS Testing Information, David Baron)

LDB, dbaron@dbaron.org