I have made a Tag Cloud type deal on my website and when you go to look at 1 tag
Example:

notice the first row looks like its spaced by 2 spaces and the last row is spaced by 1.
CSS
.tabcontent{
display:none;
}
Code
$tag_movies_result = mysql_query("SELECT * FROM tags WHERE tagname='$n' AND movie > 0");
$total_times_used_movies = mysql_num_rows($tag_movies_result);
<div id="movies" class="tabcontent">
<?php if ($total_times_used_movies > '0') { ?>
<table width="100%">
<tr>
<td>
<?php
while ($row = mysql_fetch_array($tag_movies_result))
{
$movies_to_tag_result = mysql_query("SELECT * FROM movies WHERE id=".$row['movie']." ORDER BY name ASC");
while ($row = mysql_fetch_array($movies_to_tag_result))
{
?>
<a href="./movie.php?id=<?php echo $row['id']; ?>" title="<?php echo $row['name']; ?> (<?php echo $row['year']; ?>)"><img src="./images/movies/<?php echo $row['id']; ?>.jpg" width="150" height="150" border="0" alt="<?php echo $row['name']; ?>" /></a>
<?php } } ?>
</td>
</tr>
</table>
<?php }else{ ?>
NO MOVIES WITH THIS TAG.
<?php } ?>
</div>
yet on this page http://i51.tinypic.com/ncms9c.png it uses the same exact code and displays correctly
I think the simplest solution would be to scrap the table completely, convert all those
<td>s to<div>s and just give them the CSSfloat:left;. For this demo I just put the CSS inline, but you’ll want to put it in a CSS file when you get this working.