$strHtml = '<table class="blah">';
$intCount = 0;
for($i = 0; $i < 2; $i++) {
$strHtml .= '<tr>';
for($j = 0; $j < 2; $j++) {
$strHtml .= "<td>{$arrResult[$intCount]}</td>";
$intCount++;
}
$strHtml .= '</tr>';
}
$strHtml .= '</table>';
That is a very untidy example. I never usually mix HTML and PHP, so to better the above, I would be inclined to template it and have a separate template for each table cell. But that should be enough to work with and improve upon.
R.