Chiraku
10-21-2007, 08:41 PM
I have a table, and inside a
<tr><td width='71%'>Info to the left (want info to the right too)</td></tr>
in that same table, I want to put some info to the right, and I had managed to do so, but it always creates a space, like I pressed enter, then puts the info. Any help would be appreciated, thank you.
kitchenwench
10-21-2007, 09:37 PM
I'm not too sure what it is that you're attempting to do with the table, so I'm a bit hesitant in answering, but I'll give it a shot.
I'm assuming that you want two columns of text to appear within the cell? I'm still new to this, but I think the way to go about it would be nested divs inside the cell:
<div>
<div class="left">X</div>
<div class="right">X</div>
</div>
And in your CSS stylesheet, you'd have something roughly resembling the following
div .left {
width:50%
float:left;
}
div .right {
width: 50%;
float:left;
}
I'm still new to HTML/CSS, but I *think* that should give you what you need. One of the more experienced members here will probably be able to give you more help...
*EDIT:
Oh, I'm not sure...were you wanting two columns, one at 71% and the other at 29%? If so, remove the percent value from the cell's code and just replace the percentages in the CSS markup with the relevant amounts.
not sure I fully understand either but wouuld this work?
<tr><td>column 1 content</td><td>info you want to the right goes here.</td></tr>
I would suggest that you make the table a fixed width for the sake of consistency, though your specific layout may dictate otherwise.
bazz