Previous Message
Next Message

RE: [css-d] vertical align and doctype

Sent by RUST Randal on 29 January 2002 07:07

The easiest way that I have come across for properly achieving the vertical
alignment of text in a table data cell is to do this:


td {
	font: 12px arial;
	line-height: 24px; }


You just set the value of your line-height to double that of the text.


-----Original Message-----
From: Philippe Wittenbergh [EMAIL-REMOVED]]
Sent: Tuesday, January 29, 2002 6:12 AM
Subject: Re: [css-d] vertical align and doctype

Hum. If I understand all this correctly, you can align something in 
a box by playing with the margin (top, bottom). Aligning something 
inline is more tricky, I've successfully aligned images inline in a 
<div> or a <p> by using {vertical-align:middle}. This works fine in 
all version 5+ browsers. Aligning words should be possible, but I 
had problems with it in IE5.5Windows. haven't tried since then, so 
I'm not sure about IE6.



On Tuesday, January 29, 2002, at 06:20 , Peter-Paul Koch wrote:

> Again, too little. This is only about TD's. I want vertical-align 
> to work on *anything* inside a box.
> I'm really very concerned about this problem. Why haven't the 
> creators of the specs foreseen that we need a simple way of 
> vertical aligning?
> ppk

oo--oo --oo--oo --oo--oo --oo--oo --oo--oo--oo--oo
Philippe Wittenbergh
online image gallery :

css-discuss mailing list
Previous Message
Next Message

Possibly related: