genCalendar($month,$day,$year)); ?> 27; $lastday--) { $monsta = checkdate($month,$lastday,$year); if ($monsta) { break; } } print "
"; print "$month - $day - $year

"; print ""; print ""; for ($x = 0; $x < 7; $x++) { print ""; } print ""; print ""; for ($z = 0; $z < 7; $z++) { if ( $z < $firstDayOfMonth ) { print ""; } else { break; } } for ($z = 1; $z < $stopMe ; $z++) { print ""; } print "\n"; $hold = $z; $hold--; for (;$z <= $lastday; $z++) { print ""; $wood = $z - $hold; if ( $wood % 7 == 0) { print "\n"; } } print "
$daysOfWeek[$x]
$z
$z
"; print "
"; } } ?>