Interesting approach...
Well... to answer your question, take a look at your switch cases...
case 1: "<TR>"."<TD width=25%>". print("Day ".$i." : ".gmdate("j M Y", $nextday+86400)."</TD>");
Your <tr> and <td>'s are not getting printed out... only the stuff within your print() statement are... try reorganizing it like this.
print "<tr><td>Day $i: " . gmdate("j M Y", $nextday + 86400) . "</td>";
Do the same for the others as well... You can place $variables inside of " ", which makes it much easier. You cannot, however, do the same for functions. Also, you may look into using a modulus for this. They are really useful for loops of this nature... ie:
<table border='1' cellpadding='2' cellspacing='2' width='500'>
<?
$nextday = time();
$row_length = 3;
$current_day = 1;
for($i = 0; $i < 28; $i++, $current_day++, $nextday += 86400) {
if( ($i % $row_length) == 0) {
print "<tr>";
}
print "<td align='center'>Day $current_day: " . gmdate("j M Y", $nextday) . "</td>";
if( ($i % $row_length) == ($row_length - 1) ) {
print "</tr>";
}
}
?>
</table>
Good luck...