cannot get calender function to stop writing [SOLVED]
Posted: Sat Nov 26, 2005 9:33 pm
Cannot get calender program to stop writing td cells in last row.
any suggestions?
HawleyJR:
Please use tags when posting code.
viewtopic.php?t=21171
any suggestions?
Code: Select all
if ($week==1)
{
echo"<tr>";
for ($a=0; $a<$firstday; $a++)
{
echo "<td> </td>";
}
for ($a=$firstday; $a<=$endofweek; $a++)
{
echo"<td align=\"top\"><a href=\"http://xxx.xx.xx/~xxx/calender.php?$p='results'&day=$day&month=
$m&year=$y\">$day</a></td>";
$day++;
}
echo"$firstday <br/>";
echo"$daysofmonth";
}
$week=2;
echo"</tr>";
echo"<tr>";
[b] while ($week<=$numweeks)
{
for ($a=0; $a<=6; $a++)
{
echo"<td align=\"top\"><a href=\"http://xxx/~xxx/calender.php?$p='results'&day=$day&month=
$m&year=$y\">$day</a></td>";
$day++;
}
$week++;
echo"</tr>";
}[/b]Please use tags when posting code.
viewtopic.php?t=21171