Ok, on this site i’m working on i have values being grabbed from a database. I need them to be displayed 3 columns across then create a new row. there is also a caption that will go with each item so there will need to be two rows(one for the img and another for the caption) and it will need to span 3 columns across…here is what i have.
[code=php]
<?PHP
while($img = mysql_fetch_assoc($result))
{
?>
<tr>
<?PHP
for($i=”1″;$i<=”3″;$i++)
{
?>
<td width=”30%”>
<img src=”images/<?PHP echo $img[“name”]; ?>” />
</td>
<?PHP
} //end the for statment
?>
</tr>
<tr>
<?PHP
for($i=”1″;$i<=”3″;$i++)
{
?>
<td>
<?PHP echo nl2br($img[“caption”]); ?>
</td>
<?PHP
}//end the other for statment
?>
</tr>
<?PHP
}//end the while statement
?>