>>179
foreach ($hoge as $key=>$val) {
if ($key % (NUMCOLS - 1) == 0) {
echo "<tr>"."\n";
} elseif ($key % NUMCOLS == 1) {
echo "<tr>"."\n";
}