You can use modulus operation.
$i = 1;
foreach($records as $record){
echo $record;
if ($i % 10 == 0)
echo '<hr />';
$i++;
}
1
solved How can I add a new row in a table every 10 columns automatically?
You can use modulus operation.
$i = 1;
foreach($records as $record){
echo $record;
if ($i % 10 == 0)
echo '<hr />';
$i++;
}
1
solved How can I add a new row in a table every 10 columns automatically?