I\'m trying to make a dynamic table with PHP. I have a page which displays all the pictures from a database. I need the table to be of 5 columns only. If more than 5 pictur
$max_per_row = 5; $item_count = 0; echo ""; echo ""; foreach ($images as $image) { if ($item_count == $max_per_row) { echo ""; $item_count = 0; } echo ""; $item_count++; } echo ""; echo "";