require_once("header_includes.php"); $numAvail = 0; // get dynamic info for page //get banner for home page $queryBannerHome = "SELECT * FROM banners WHERE banner_category = 'home' LIMIT 1"; $bannerHome = $db->get_row($queryBannerHome); //get sponsor and event info for next event //get Next Event $queryEvent = "SELECT "; $queryEvent .= "events.event_id AS eventId, "; $queryEvent .= "sponsors.sponsor_name as sponsorName, "; $queryEvent .= "sponsors.sponsor_logo as sponsorLogo, "; $queryEvent .= "sponsors.sponsor_url AS sponsorUrl "; $queryEvent .= "FROM events "; $queryEvent .= "INNER JOIN sponsors ON events.sponsor_id = sponsors.sponsor_id "; $queryEvent .= "WHERE events.event_date > DATE_SUB(CURDATE(), INTERVAL 14 DAY) and events.active='1' ORDER BY events.event_date ASC LIMIT 1 "; $event = $db->get_row($queryEvent); ob_start(); ?>