Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

why does this table cell have so much height?

0 views
Skip to first unread message

TR

unread,
Jun 13, 2004, 9:33:30 AM6/13/04
to
The following HTML/CSS works pretty much as expected in Opera and
Firefox, but in IE6 the cell occupied by the transparent image (the
first cell in the second table) has a vertical dimension which I'd like
to elminate:

http://www.timolimo.com/firefox/test2.htm

I'd be grateful for suggestions.
Thanks!
TR


s_m_b

unread,
Jun 16, 2004, 4:40:29 AM6/16/04
to
TR <t...@my.biz> wrote in news:MPG.1b3621a25201d64e9896c9
@msnews.microsoft.com:

<img src='middle.gif' style="width:100%;height:22px">
I'm assuming you're talking abnout that?
use the img height and width attributes. Then you can flatten
the height to 1 if you wish.

Timo

unread,
Jun 16, 2004, 9:44:55 AM6/16/04
to
Thanks for the reply, but no, I was talking rather about the cell containing
the transparent image, whose height is set to 1px (as is the image it
contains) but the cell is being displayed about 22px high. I annotated the
source:

<TR>
<!-- why does this cell have so much height in IE6? -->
<TD style="width:150px;height:1px; border-right:1px solid
#CCCCFF;border-left:1px solid #CCCCFF ">
<IMG src="stretcherimg.gif" style="width:150px;height:1px"/>
</TD>
</TR>

Timo
"s_m_b" <smb20...@hotmail.com> wrote in message
news:Xns950A624EB42F7sm...@207.46.248.16...
: TR <t...@my.biz> wrote in news:MPG.1b3621a25201d64e9896c9

: >
: >
: >
: >
: >
:


Pascal Chevrel

unread,
Jun 16, 2004, 12:43:33 PM6/16/04
to

Le 16/06/2004 15:44, Timo a ecrit :

> Thanks for the reply, but no, I was talking rather about the cell containing
> the transparent image, whose height is set to 1px (as is the image it
> contains) but the cell is being displayed about 22px high. I annotated the

td img {display:block;}

Images are inline elements with a line-height value.

You should also set a strict DTD definition so as to force all browsers
to be as respectful as possible to the standards (and thus to have a
more similar behaviopur).

Pascal

--
Pascal Chevrel - Mozilla Champion
FAQ Mozilla/Netscape 7 en français : http://www.chevrel.org/fr/faq/
Foros Mozilla en español : http://www.chevrel.org/es/foros/

Timo

unread,
Jun 16, 2004, 7:41:12 PM6/16/04
to
Thank you, Pascal!
Timo

"Pascal Chevrel" <pascal.chev...@free.fr> wrote in message
news:40d078b4$0$279$636a...@news.free.fr...
:
:
: td img {display:block;}

:


0 new messages