It's because the image in the right column requires that height. If the image were smaller, or if you just add more text to the left column, there would not be any gap. To easily see what I mean, try adding a border to all the cells. Add this CSS
Code:
td {
border: 1px solid #f00;
}
Now, to the solution. The clever way of solving this is to let the right cell that has the image stretch down over two rows, instead of one as it does now. I'll give you an example:
Currently, your code looks like this
HTML Code:
<table>
<tr>
<td>Left column with text</td>
<td>Right column with image</td>
</tr>
<tr>
<td>Left column with more text</td>
<td>Empty cell</td>
</tr>
</table>
Change it into this
HTML Code:
<table>
<tr>
<td>Left column with text</td>
<td rowspan="2">Right column with image, that will stretch over 2 rows instead of 1</td>
</tr>
<tr>
<td>Left column with more text</td>
</tr>
</table>
Also, you have two empty rows in the bottom of the table, you can remove those. I mean the ones that look like this
HTML Code:
<tr>
<td></td>
<td></td>
</tr>
<tr>
<td></td>
<td></td>
</tr>
__________________
Your answers will only be as good as your question. Formulate it well and give all the necessary information.
Last edited by lizciz; 08-13-2011 at 08:15 PM..
|