[thelist] css child and descendant selectors

Peter-Paul Koch gassinaumasis at hotmail.com
Tue Feb 12 08:37:11 CST 2002

><li>child of 'ol'
><li>child of 'ol'
><li>descendant of 'ol'; child of 'ul'
><li>descendant of 'ol'; child of 'ul'
><li>child of 'ol'
>ol li {styles} should apply to all the li tags.
>ol > li {styles} should apply only to the three marked 'child of ol'?

Yep, correct. Of course browser compatibility isn't what it's supposed to
be. Basically the > selector is not supported by Explorer on Windows (and
Netscape 4, of course).

Well, maybe, just maybe, the ol>li styles would also apply to the ul since
it's a child of an ol>li and might inherit some values. Not sure.


Send and receive Hotmail on your mobile device: http://mobile.msn.com

More information about the thelist mailing list