Save your HTML page as a .php file, and you're done. Then you can include php code where you wish. yourfile.php could be like this:
<table>
<tr>
<?php
foreach($array as $value)
echo "<td>$value</td>";
?>
</tr>
</table>
You can mix php code inside html where you need it. This is, in fact, the most desirable method of coding. The php parser only does work on the php and doesn't touch the HTML.