3v4l.org

run code in 300+ PHP versions simultaneously
<?php $end=82; //will get all this data from a dabase $rows=ceil($end/8); $x=0; $start=0; ?> <table> <?php while($x<=$rows) { echo "<tr>"; for ($y = 0; $y < 8; $y++, $start++) { if ($start <= $end) echo "<td>$start</td>"; } echo "</tr>"; $x++; } ?> </table>

preferences:
32.78 ms | 402 KiB | 5 Q