Tables within tables

liunx

Guest
Hi!<br />
<br />
I've just joined this forum and wished to ask what maybe a very basic question.<br />
<br />
I have a main table it is 2 cols by 1 row. Inside each of these is another set of tables. The right col is the navigation one. I have set this to a fixed width.<br />
The left one is the main area for information. It contains several other tables, one of which I'd like to expand as data is put in or taken out.<br />
<br />
The problem is that when the large main table (cell) is expanded it centres the table on the right (menu) area to the middle of the main table. What I need is anything in the right hand maintable cell to stay at the top all the time and not move down. Is there a code instruction to do this? I tried valign, but Dreamweaver seems to over look it. Or am I placing it in the wrong place. Can someone help please?<br />
<br />
Thanks, Aardvark:confused:<!--content-->I'm as confused as you :confused:, can you make it a bit clearer aardvark_html? :)<!--content-->Oh dear, I thought that was pretty clear :( <br />
<br />
I have nested tables inside a main table, if one cell of the main table is enlarged, then the nested table in the other main table cell centres and I want it to be at the top of that cell.<br />
<br />
Is that clearer?<!--content-->First up it is often helpful if you post some code or show a link to your site.<br />
<br />
Second welcome to the forums, enjoy and good vibes.<br />
<br />
Third I think your problem might be a TR problem. I know Scoutt would disagree with me on this one as he has in the past... but find the TR that nests your table and insert the attribute valign="top"... ie <tr valign="top"><br />
<br />
Hope that helps... if not post some code here or a link.<!--content-->I found this code. Will this do the trick?<br />
<br />
<br />
<div style="position: relative; top: 150px"><br />
<table border="1" align="center" height="300" width="300"><br />
<tr><br />
<td><br />
</td><br />
</tr><br />
</table><br />
</div><!--content-->Show us your code / url!<!--content-->It's not on-line, I'll bring the code tomorrow.<!--content-->to align something in a table cell to the top use css<br />
<br />
<td style="vertical-align:top;"><br />
properies can be :top, middle, bottom.<br />
better to throw it into your stylesheet if you have one!<br />
<br />
valign="top" is deprecated:D<!--content-->Thanks I'll try this<!--content-->How would I write that as a class, and call it?<br />
<br />
Sorry to pester<!--content--><style type="text/css"><br />
td.1 {vertical-align:top;}<br />
</style><br />
<br />
<br />
<td class="1"><br />
<br />
this way you place the styles in the head, in an external stylesheet open up notepad and throw the style in their without the style tags (just the td.1 part basically)save it as a text document 'filename.css', , use the td class="1" and place this in the head<br />
<br />
<link rel="stylesheet" type="text/css" href=http://www.htmlforums.com/archive/index.php/"filename.css" ><!--content-->Thank you so much:)<!--content-->you're welcome :)<!--content-->Well, sad to say that all this advice didn't work.<br />
<br />
I found another mention, which was:<br />
<br />
<tr valign="top"><br />
<br />
and this did the trick perfectly.<br />
<br />
Anyway, thanks for the effort everyone, and problem solved.:)<!--content-->Originally posted by aardvark_html <br />
Well, sad to say that all this advice didn't work.<br />
<br />
I found another mention, which was:<br />
<br />
<tr valign="top"><br />
<br />
and this did the trick perfectly.<br />
<br />
Anyway, thanks for the effort everyone, and problem solved.:) <br />
<br />
Isn't that what I said??? Right at the begining of the thread (almost)... sheesh, glad it worked.<!--content-->Sorry. I meant you were the one that posted the answer.<br />
<br />
It worked, great thanks.<br />
:)<!--content-->It's ok, I wasn't looking for the credit... just assumed you would have taken the advice in the order it came. As long as it worked.. good vibes.<!--content-->
 
Back
Top