I have a mySql query returns 50 results. Is there a way to move the loop in sections.
I need to create 4 tables of data in four CSS columns. As you can see in my code i can loop through the 1st 13 records no problem.
What I need to do is start the next table with the 14th record. Thanks,
<!-- Column one start -->
<?
echo "<center>";
echo "<table>";
echo "<tr>";
include('config.php');
$result = mysql_query("SELECT * FROM `state`") or trigger_error(mysql_error());
$count = 0;
while( $count < 13 && $row = mysql_fetch_array($result)){
foreach($row AS $key => $value) { $row[$key] = stripslashes($value); }
echo "<td><a href=aCity.php?state_id={$row['state_id']}>" . nl2br( $row['state']) . "</a></td>";
echo "</tr>";
$count = $count + 1;
}
echo "</table>";
echo "</center>";
?>
<!-- Column one end -->