...

View Full Version : cantre table as vertically



zodehala
11-01-2008, 10:46 PM
Suppose that my table is like following



<table id="table1" width="100%" border="0" cellspacing="1" cellpadding="0">
<tr>
<td>
<table id="table2" width="100%" border="0" cellspacing="1" cellpadding="0">
<tr>
<td>&nbsp;</td>
</tr>
</table></td>
<td>
</td>
</tr>
</table>




when i write a long text inside right part table in left is center vertically but i want it is top always (see link)




http://img216.imageshack.us/my.php?image=snap1su1.gif

gnomeontherun
11-01-2008, 10:49 PM
What we need to see is the CSS code that is associated with the table.

Otherwise you have to use this CSS with the td


#table1 td{
vertical-align: top;
}

zodehala
11-01-2008, 11:26 PM
What we need to see is the CSS code that is associated with the table.

Otherwise you have to use this CSS with the td


#table1 td{
vertical-align: top;
}

it did not run. it is still in center

gnomeontherun
11-01-2008, 11:32 PM
Well what is the code for your page? Which one do you want to be top?

Also, using tables for layout is bad, so perhaps there is a better method if we can see the whole code.

zodehala
11-02-2008, 12:34 AM
<table id="table1" width="100%" border="0" cellspacing="1" cellpadding="0">
<tr>
<td>
<!--table i want to center vertically-->
<table id="table2" width="100%" border="0" cellspacing="1" cellpadding="0">
<tr>
<td>&nbsp;</td>
</tr>
</table>
<!--table i want to center vertically-->
</td>
<td> </td>
</tr>
</table>

twodayslate
11-02-2008, 01:22 AM
http://bonrouge.com/3c-hf-fluid-lc.php

zodehala
11-02-2008, 08:02 PM
i can not do it would you give me a sample ?

gnomeontherun
11-02-2008, 09:26 PM
That is a sample...that doesn't use tables for layout. Which is not good to do by the way.

Millenia
11-02-2008, 09:30 PM
That is a sample...that doesn't use tables for layout. Which is not good to do by the way.

Agreed. It's time to visit my favorite link. (http://www.hotdesign.com/seybold/)



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum