$message "; } //$category_list = get_category_list(); $restaurant_discount_list = get_restaurant_discount_list('4'); ?> Restaurant Menus | <? echo $site_title; ?> "> query($todays_events_query); //echo "Add Event"; //echo "
"; while ($r = mysqli_fetch_array($todays_events_result)) { $count++; $id=$r["ID"]; $event_name=$r["EVENT_NAME"]; $address=$r["ADDRESS"]; $city=$r["CITY"]; $state=$r["STATE"]; $category=$r["CATEGORY"]; $date = date("Y-m-d"); $scheduled_date=$r["SCHEDULED_DATE"]; if(empty($scheduled_date)) { $scheduled_date = "Today"; } $name=trim($r["VENUE"]); $details=stripslashes($r["DETAILS"]); $details = mb_convert_encoding($details, "UTF-8"); if(empty($details)) { $details = ''; } else { $details = "
  • $details

  • "; } $name_search=$connect->real_escape_string($name); $restaurant_count = "SELECT COUNT(ID) AS COUNT FROM restaurants WHERE CITY = '$site_city' and STATE = '$site_state' and NAME='$name_search'"; $results_count = $connect->query($restaurant_count); while ($c = mysqli_fetch_array($results_count)) { $count=$c["COUNT"]; if($count > 1) { $double = "/".$id; } else { $double = ""; } } $link_name=get_clean_name($name).$double; $rating_image = get_rating_image($rating); if(restaurant_exists(str_replace("'", "''", $name)) == '0') { $venue_link = $name; } else { $venue_link = "$name"; } $time = strtotime($date); $newformat = date('c',$time); /* echo "

    $event_name


    "; $event_array[] = array( 'venue_id' => "$id", 'event_name' => "$event_name", 'event_url' => "", 'venue_name' => "$name", 'venue_url' => "http://www.wincfood.com/venue/$link_name/", 'start_date' => "$newformat", 'end_date' => "", 'description' => "$details", 'location' => "$address, $city, $state", 'type' => "reoccurring" ); //if($name <> '') { //$event_microdata .= get_event_microdata($name, $address, $city, $state, $event_name, $date, $details); //} } //echo "
    "; $this_week_events_query = "SELECT events.ID, events.EVENT_NAME, (select address from restaurants where name = events.venue and city = 'Winchester' and state ='VA' limit 1) as ADDRESS, '$site_city' as CITY, '$site_state' as STATE, events.CATEGORY, events.DATE, DATE_FORMAT(events.DATE,'%W, %M %e at %l:%i %p') AS SCHEDULED_DATE, events.VENUE, events.DETAILS FROM events WHERE events.DATE < DATE_FORMAT(DATE_ADD(CURRENT_TIMESTAMP(), INTERVAL 21 DAY),'%Y%m%d000000') AND events.DATE >= DATE_FORMAT(CURRENT_TIMESTAMP(),'%Y%m%d000000') AND events.APPROVED='Y' ORDER BY events.DATE ASC"; $this_week_events_result = $connect->query($this_week_events_query); //echo "
    "; while ($r = mysqli_fetch_array($this_week_events_result)) { $count++; $id=$r["ID"]; $event_name=$r["EVENT_NAME"]; $address=$r["ADDRESS"]; $city=$r["CITY"]; $state=$r["STATE"]; $category=$r["CATEGORY"]; $date=$r["DATE"]; $scheduled_date=$r["SCHEDULED_DATE"]; if(empty($scheduled_date)) { $scheduled_date = "Today"; } $name=trim($r["VENUE"]); $details=stripslashes($r["DETAILS"]); $details = mb_convert_encoding($details, "UTF-8"); if(empty($details)) { $details = ''; } else { $details = "
  • $details

  • "; } $name_search=$connect->real_escape_string($name); $restaurant_count = "SELECT COUNT(ID) AS COUNT FROM restaurants WHERE restaurants.CITY = '$site_city' and restaurants.STATE = '$site_state' and NAME='$name_search'"; $results_count = $connect->query($restaurant_count); while ($c = mysqli_fetch_array($results_count)) { $count=$c["COUNT"]; if($count > 1) { $double = "/".$id; } else { $double = ""; } } $link_name=get_clean_name($name).$double; $rating_image = get_rating_image($rating); if(restaurant_exists(str_replace("'", "''", $name)) == '0') { $venue_link = $name; } else { $venue_link = "$name"; } $time = strtotime($date); $newformat = date('c',$time); /* echo "

    $event_name


    "; $event_array[] = array( 'venue_id' => "$id", 'event_name' => "$event_name", 'event_url' => "", 'venue_name' => "$name", 'venue_url' => "http://www.wincfood.com/venue/$link_name/", 'start_date' => "$newformat", 'end_date' => "", 'description' => "$details", 'location' => "$address, $city, $state", 'type' => "scheduled" ); } */ ?>

    Menus