set_query("SELECT * from coastweb.room_rate_calendar WHERE date = '" . $cal_values['stamp'] . "' && property = '" . $property . "'"); $query->query(); //if statement and SQL to create month if ($query->get_row_count() == "0") { $x = "1"; while ($x <= date(t, $cal_values['stamp'])) { $cal_values['days'] = mktime(0, 0, 0, $cal_values['var_month'], $x, date(Y)); //SQL to create $query2->set_query("INSERT INTO coastweb.room_rate_calendar (date, rate, property, last_updated) VALUES ('" . $cal_values['days'] . "', 'N/A', '" . $property . "', '" . time() . "')"); $query2->query(); //incriment counter $x++; } } //increment month counter $cal_values['var_month']++; } // Delete Old Month Records /////////////////////////////////////////////////////////////////////////////////// //determine variables $cal_values['current_month'] = date(n); $cal_values['end_month'] = $cal_values['current_month'] + 3; if ($cal_values['end_month'] == "15") { $cal_values['end_month'] = "3"; } else if ($cal_values['end_month'] == "14") { $cal_values['end_month'] = "2"; } else if ($cal_values['end_month'] == "13") { $cal_values['end_month'] = "1"; } //check to see which months exist $cal_values['var_month'] = "1"; while ($cal_values['var_month'] <= "12") { //create timestamp $cal_values['stamp'] = mktime(0, 0, 0, $cal_values['var_month'], 1, date(Y)); //look for timestamp $query->set_query("SELECT * from coastweb.room_rate_calendar WHERE date = '" . $cal_values['stamp'] . "' && property = '" . $property . "'"); $query->query(); //if statement and SQL to create month if ($query->get_row_count() != "0" && ($cal_values['var_month'] < $cal_values['current_month'] && $cal_values['var_month'] > $cal_values['end_month'])) { $x = "1"; while ($x <= date(t, $cal_values['stamp'])) { $cal_values['days'] = mktime(0, 0, 0, $cal_values['var_month'], $x, date(Y)); //SQL to create $query2->set_query("DELETE FROM coastweb.room_rate_calendar WHERE date = '" . $cal_values['days'] . "' && property = '" . $property . "'"); $query2->query(); //incriment counter $x++; } } //increment month counter $cal_values['var_month']++; } ?> Las Vegas Room Rate Calendar | South Point Hotel Las Vegas
 
 
Make Online Reservations
 
set_query("SELECT * from coastweb.properties WHERE symbol='" . $rates['property'] . "'"); $query->query(); $query->reset(); $row = $query->get_next(); $prop['name'] = $row['name']; $prop['roomtype'] = $row['roomtype']; $prop['bgcolor'] = $row['bgcolor']; $cal_values['current_month'] = date(n); $query->set_query("SELECT * from coastweb.room_rate_calendar where property = '" . $rates['property'] . "'"); $query->query(); $query->reset(); while ($row = $query->get_next()){ $rates[$row['date']] = $row['rate']; if ($single != "true") { $rates['last_updated'] = $row['last_updated']; $single = $single; } } //display calendar $cal_values['print_month'] = $cal_values['current_month']; $cal_values['end_month'] = $cal_values['current_month'] + 3; ?>
This calendar is meant to be a guide to online room rates and availability at the South Point. The rates are updated daily for available rooms. Rates and availability are subject to change at any time and the change may not be reflected on this calendar. N/A = Not Available

> > "0") { echo ""; } ?> " . date("m.d.y", $cal_values['days']) . "
" . $rates[mktime(0, 0, 0, $cal_values['print_month'], $x, date(Y))] . ""; } else { echo ""; } if (date(w, $cal_values['days']) == "6") { echo ""; } $x++; } ?>
Sunday Monday Tuesday Wednesday Thursday Friday Saturday
" . date("m.d.y", $cal_values['days']) . "
$" . $rates[mktime(0, 0, 0, $cal_values['print_month'], $x, date(Y))] . "