ok i'm trying to do this:
PICTURE PICTURE PICTURE
PICTURE PICTURE PICTURE
PICTURE PICTURE
sort information fromt the database so it shows 3 per row, here is the coding:
<?
include('lib/config.php');
$sql = "SELECT * FROM submissions WHERE contest=$contest_id";
$r = mysql_query($sql);
$numofrows = mysql_num_rows($r);
for($total = 0; $total < $numofrows; $total++) {
$row = mysql_fetch_array($r); //get a row from our result set
$picid = $row['id'];
if($total % 3) { //this means if there is a remainder
?>
<img src=imgproc.php?subid=<?=$picid?>>
<br>
<?
} else { //if there isn't a remainder we will do the else
echo "<img src=imgproc.php?subid=$picid> ";
}
}
//now let's close the table and be done with it
?>