W3C home > Mailing lists > Public > www-html@w3.org > June 2002

HTML Table Formatting Question

From: Clarence <clarence@mac.com>
Date: Thu, 20 Jun 2002 17:48:53 -0400
To: www-html@w3.org
Message-Id: <83C5881E-8497-11D6-A20A-00039373DEB0@mac.com>

Hi all,
I'm new to the list and have a question regarding HTML tables and the 
W3C spec. I'm not sure if this should go to this list of the Style list, 
so please let me know if I'm posting to the wrong list.

After reading some threads in the archives, I'm still at a loss at how 
to do something like the following:

<table cellpadding="0" cellspacing="0" border="0" height="1">
	<tr>
	<td height="1" bgcolor="#CCCCCC"><img src="spacer.gif" border="0" 
height="1" width="100"></td>
	</tr>
</table>

We're testing on Mozilla and it seems that the image is now adjusted to 
the baseline in the cell - which appears to be in the center causing the 
cell height to increase.
I read that this can be adjusted in the style sheet using line-height:0, 
but doing the following:

td.spacer {
	line-height: 0;
}

<table cellpadding="0" cellspacing="0" border="0" height="1">
	<tr>
	<td class="spacer" height="1" bgcolor="#CCCCCC"><img 
src="spacer.gif" border="0" height="1" width="100"></td>
	</tr>
</table>

Does not work as well. Is this functionality no longer supported? Please 
let me know. Thanks.


Clarence
Received on Thursday, 20 June 2002 17:49:02 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 27 March 2012 18:15:52 GMT