I am pulling images from my database and am going to display all images from an artist on one page. What I want to be able to do is to display them in rows of 4 and however many columns that are needed. Can someone help me with the code to displaying them in the row?
Here is my code that displays them in 1 column.
$result2 = mysql_query("SELECT * FROM image WHERE artid LIKE '$search' ORDER BY title") or die(mysql_error());
$num_rows=mysql_num_rows($result2);
if ($num_rows != "0")
{
$count = count(0);
while ($r=mysql_fetch_array($result2))
{
$imgid=$r['imgid'];
$artid=$r['artid'];
$title=$r['title'];
$dtxt_1 =$r['dtxt_1'];
$dt=$r['dt'];
$medid=$r['medid'];
$size_inch=$r['size_inch'];
$size_cm=$r['size_cm'];
$musid=$r['musid'];
$movid=$r['movid'];
$genid=$r['genid'];
$perid=$r['perid'];
$bio=$r['bio'];
$keywords=$r['keywords'];
$notes=$r['notes'];
$verified=$r['verified'];
//display the row
echo "<div id='artContent'>";
echo "<span class='image'>";
echo $count++ ;
echo ". <div class=img-shadow><a href='image/$artid/$imgid.jpg' class='thickbox' title='$title by $fullName'>
<img src='image/thumb/$artid/$imgid.jpg' border=0 width=75 height='100' title='$title by $fullName' align=left valign=top></a></div></span>";
echo "<span class='info'>";
echo "<a href='image.php?imgid=$r[imgid]' title='$title by $fullName'>".$title."</a> <br>".$dt."<br>".$medid."<br>".$bio." ";
echo "</span></div>";
}
}