while ($event = $DB_site->fetch_array($events)) { if ($event[eventdate] != $lastdate) {
while ($event = $DB_site->fetch_array($events)) { if ($event[eventdate] != $lasteventdate) {