Align Columns from Multiple Tables

J

justengland

I have a web page that has 4 tables, 1 table is the holder for the
other 3 tables. I want to columns to line up in the 3 tables, but the
text within the table cells is dynamic so the column widths from table
to table are inconsistent. Is there any tricks to make the 3 table
line up?

Code looks something like this
<table bordercolor=black border=2>
<tr>
<td>
<table bordercolor=green border=2>
<tr>
<td>Some Text</td>
<td>More Text</td>
<td>This Text</td>
</tr>
</table>
<table bordercolor=blue border=2>
<tr>
<td>Longer Text goes here</td>
<td>Longer Text goes here</td>
<td>Longer Text goes here</td>
</tr>
</table>
</td>
</tr>
</table>
 
R

Remy

Obvious answer is that you could try something like this:

<table bordercolor=black border=2>
<tr bordercolor=green border=2>
<td>Some Text</td>
<td>More Text</td>
<td>This Text</td>
</tr>
<tr bordercolor=blue border=2>
<td>Longer Text goes here</td>
<td>Longer Text goes here</td>
<td>Longer Text goes here</td>
</tr>
</table>

depends how you want your table to look like. And I think adding the
border color to the tr element is actually not a good idea, but you
could add it to the td elements.
Then, everybody recommends css nowadays...
 
J

justengland

The problem I was haveing was because I had set the table width, and
then set the column widths. To get the alignment correct you can
either set the table width or column widths, when you mix the parser
messes everything up.
 

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

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,014
Latest member
BiancaFix3

Latest Threads

Top