how to aign text in tablecells using css-file

H

Hugo de Payns

I like to align the text in the td to the top of the cell.
Using <tr valign=top> in html works fine, but i like to have the same
effect in the use of an css.file.

Is there a way to achive this??

Just an table example
<TABLE>
<TR>
<TD>text</TD>
<TD>text text</TD>
<TD>text text text</TD>
<TD>text text text text</TD>
</TR>
</TABLE>

TIA
 
S

Steve Pugh

Hugo de Payns said:
I like to align the text in the td to the top of the cell.
Using <tr valign=top> in html works fine, but i like to have the same
effect in the use of an css.file.

vertical-align: top;

Steve
 
K

Kris

Hugo de Payns said:
I like to align the text in the td to the top of the cell.
Using <tr valign=top> in html works fine, but i like to have the same
effect in the use of an css.file.

Is there a way to achive this??

[table source snipped]

td, th { vertical-align: top; }
 
R

rf

Hugo de Payns said:
I like to align the text in the td to the top of the cell.

vertical-align: top;
Using <tr valign=top> in html works fine, but i like to have the same
effect in the use of an css.file.

Is there a way to achive this??

Just an table example
<TABLE>
<TR>
<TD>text</TD>
<TD>text text</TD>
<TD>text text text</TD>
<TD>text text text text</TD>
</TR>
</TABLE>

Does not look like tabular data to me :)

Cheers
Richard.
 
L

Leif K-Brooks

Hugo de Payns said:
I like to align the text in the td to the top of the cell.
Using <tr valign=top> in html works fine, but i like to have the same
effect in the use of an css.file.

td {
vertical-align : top;
}
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,581
Members
45,056
Latest member
GlycogenSupporthealth

Latest Threads

Top