I am trying to make a table, where the $f1,$f2..etc. will be at the top, and the min increments by five at the left column.
However, I keep ending up with the $f1 header generated all along the side instead of the min increment.
The actual values in the table should be the header multiplied by the sidebar. My requests work fine, but the actual cells aren't the way i intend to have them.
<table class="table">
<?php
$max = 60;
$min = 30;
$f1= 5;
$f2= 10;
$f3= 15;
$f4= 20;
$f5= 25;
$count = array($f1,$f2,$f3,$f4,$f5);
$NumRows = $max;
echo '<br />';
for($i=$min;$i<=$NumRows;$i=$i+5){
echo '<tr>';
for($j=0; $j <= 4; $j++) {
if($i ==$min || $j ==0) {
echo '<td class="cell1">'.$count[$j].'</td>';
}
else {
echo '<td class="cell2">'.$i*$count[$j].'</td>';
}
}
echo '</tr>';
}
?>
</table>
it should essentially look like a multiplication table.
