Table column heights problems.

admin

Administrator
Staff member
OK folks. I wish to extend the center column but leave the left and right columns at the same height. I want to have the same size columns on the left and right and make the center one as big as the content in them. Im using Dreamweaver.<br />
<br />
Here's the site Im working with : <!-- m --><a class="postlink" href="http://robdougan.tcslon.com/index2.htm">http://robdougan.tcslon.com/index2.htm</a><!-- m --><!--content-->You cannot have different column heights in a table. <br />
<br />
You can add a row of empty cells and specify the cell you want taller to span that row with "rowspan=". If you have a border around the table, I guess it will look funny.<br />
<table border height=100%><br />
<tr><br />
<td height=200>This is the left</td><br />
<td rowspan=2>This is the center</td><br />
<td height=200>This is the right</td><br />
<tr><br />
</table><br />
Tested on IE 5.5<br />
<br />
Look into using CSS instead of tables for layout. You can become frustrated with the rest of us. ;)<!--content-->Well..one way I hear is to use layers..then when all are arranged the way you need it then you convert the layers to tables.....<br />
<br />
OR..perhaps manually change the attributes of the single cell...but I never tried that though....:D<!--content-->I'm so excited, can answer this!<br />
<br />
In your outside columns, set the background colour to match the page background (or transparent, if you can get it to work). So the columns seem invisible.<br />
<br />
Make an image of whatever it is that you want in your outside columns, put the image in the column with a Top valign and a T position of 0 (I've found they slide around if you don't do both). Hey presto, you now have a table that can go as long as you want - but only the centre column will show up.<br />
<br />
if you want content in your outer columns, you'll have to put layers on them but that's easy.<br />
<br />
Alternatively, why don't you stick a layer on your centre column? They come with a default scroll bar in Dreamweaver; I would have thought that made a tidier solution.<br />
<br />
Hope this works. for you. Sorry I don't know the technical terms.<br />
<br />
CAA<!--content-->The code below is the basic layout for a 3-column page where the columns show up as different heights. It's written in tables, which I assume you're using for right now.<br />
<br />
'Course I always encourage people to dump the tables and use <div>s and CSS to lay pages out. But the code below will work for you:<br />
<br />
<table cellpadding="0" cellspacing="0" border="0" width="100%"><br />
<tr><br />
<td width="20%" valign="top"><br />
<table cellpadding="0" cellspacing="0" border="0" width="100%" bgcolor="red"><br />
<tr><br />
<td width="100%"><br />
<p>Left hand column goes here</p><br />
</td><br />
</tr><br />
</table><br />
</td><br />
<td width="40%" valign="top"><br />
<table cellpadding="0" cellspacing="0" border="0" width="100%" bgcolor="green"><br />
<tr><br />
<td width="100%"><br />
<p>Middle column content</p><br />
<p>&nbsp;</p><br />
<p>&nbsp;</p><br />
</td><br />
</tr><br />
</table><br />
</td><br />
<td width="20%" valign="top"><br />
<table cellpadding="0" cellspacing="0" border="0" width="100%" bgcolor="blue"><br />
<tr><br />
<td width="100%"><br />
<p>Right column</p><br />
<p>&nbsp;</p><br />
</td><br />
</tr><br />
</table><br />
</td><br />
</tr><br />
</table><!--content-->Thanks guys!<br />
My friend suggested to use Dreamweaver and i managed to insert rows on the columns on the left and right. Thus meaning the middle could be made to look bigger than the other ones.<br />
<br />
Im going to give <div>s a go, people on here seem to use them a good deal.<!--content-->
 
Back
Top