At http://www.gavelcade.com/tests/parti...cognition.html is an
illustration of an apparent inconsistency in the way the child selection
operator > is handled with respect to tables, rows, and cells. I'm trying to
bold-face the first column of a two column table. I try the following five
variations (the five tables in the demo are assigned classes a, b, c, d, and
e, respectively):
table.a td:first-child { font-weight: bold; }
table.b tr td:first-child { font-weight: bold; }
table.c tr > td:first-child { font-weight: bold; }
table.d > tr td:first-child { font-weight: bold; }
table.e > tr > td:first-child { font-weight: bold; }
The first three variations work in Netscape 7.01, Firefox 1.0, and Opera
7.54. The last two work in none of those browsers.
I've experimented and found that the cause has nothing to do with my use of
:first-child, because if I remove it, then all the cells in the first three
tables are bolded and none of the cells in the last two tables is.
It has nothing to do with the COL elements because the same thing happens
when I remove them.
I thought it might have something to do with using the > character in the
stylesheet, but I tried both changing it to > throughout and moving the
styles to an external stylesheet, and neither made a difference in the
outcome.
--
Harlan Messinger
Remove the first dot from my e-mail address.
Veuillez ôter le premier point de mon adresse de courriel.