user667430 user667430 - 1 month ago 8
CSS Question

HTML CSS image in second column of table not displaying correctly

I am trying to create a table which has a list on the first column and an image in the second column. However when I put the image in the second column it moves the list of the first column down. Here is what happens:

image moves list down

As you can see the image moves the list down. How could I get it so it looks like this:

enter image description here

This is the code for the table.

<table border="0">
<tr>
<td>
<ul>
<li>F1</li>
<li>ALMS</li>
<li>Le Mans 24 Hour</li>
<li>WTCCBritish GT</li>
<li>BTCC</li>
<li>Toca support races</li>
</ul>
</td>
<td>
<a href="http://www.motorground.co.uk/wp-content/uploads/2013/02/track-day-0732.jpg"><img src="http://www.motorground.co.uk/wp-content/uploads/2013/02/track-day-0732-300x200.jpg" alt="PrivateTuitionimg073" width="300" height="200" class="aligncenter size-medium wp-image-23" /></a>
</td>
</tr>
</table>

Answer

You must add to your img style: float: right And position it at the bottom of te list in same cell.