Select a Month/Year Combination


\n"; foreach ($days as $day) { echo "$day\n"; } for ($count=0; $count < (6*7); $count++) { $dayArray = getDate($start); if (($count % 7) == 0) { if ($dayArray["mon"] != $month) { break; } else { echo "\n"; } } if ($count < $firstDayArray["wday"] || $dayArray["mon"] !=$month) { echo " \n"; } else { $chkEvent_sql = "SELECT event_title FROM calendar_events WHERE month(event_start) = '".month."' AND dayofmonth(event_start) = '".$dayArray["mday"]."' AND year(event_start) = '".$year."' ORDER BY event_start"; $chkEvent_res = mysqli_query($mysqli, $chkEvent_sql) or die(mysqli_error($mysqli)); if (mysqli_num_rows($chkEvent_res) > 0) { $event_title = "
"; while ($ev = mysqli_fetch_array($chkEvent_res)) { $event_title = stripslashes($ev["event_title"])."
"; } mysqli_free_result($chkEvent_res); } else { $event_title = ""; } echo "".$dayArray["mday"]. "
".$event_title."\n"; unset($event_title); $start += ADAY; } } echo ""; mysqli_close($mysqli); ?>