"; //$hidden_fields .= ""; $hidden_fields .= ""; // $hidden_fields .= ""; } else { return ""; } if ($checkin == "") { if ($gcheckin != "") { $checkin = $gcheckin; $checkin = date("Y-m-d", mktime(0, 0, 0, substr($checkin, 5, 2) + 0, substr($checkin, 8, 2) + 0, substr($checkin, 0, 4))); } else { $tomorrow = mktime(0, 0, 0, date("m"), date("d") + $config_abl["default_start_checkin"], date("Y")); $checkin = date("Y-m-d", $tomorrow); } } else { $checkin = date("Y-m-d", mktime(0, 0, 0, substr($checkin, 5, 2) + 0, substr($checkin, 8, 2) + 0, substr($checkin, 0, 4))); } if (strtotime($checkin) < strtotime(date("Y-m-d"))) { $tomorrow = mktime(0, 0, 0, date("m"), date("d") + $config_abl["default_start_checkin"], date("Y")); $checkin = date("Y-m-d", $tomorrow); } if ($nights == "") { if ($gnights != "") { $nights = $gnights; } else { $nights = $config_abl["default_nights"]; } } if ($rooms == "") { if ($grooms != "") { $rooms = $grooms; } else { $rooms = $config_abl["default_rooms"]; } } $org["checkin"] = $checkin; $org["rooms"] = $rooms; $org["nights"] = $nights; $bln = (int)substr($checkin, 5, 2); $thn = (int)substr($checkin, 0, 4); $dt = (int)substr($checkin, 8, 2); $output_ci = ""; $output_ci .= ""; $output_ci .= ""; $output_ni = ""; $output_ro = ""; $out = <<< EOT
Check In {$output_ci}  Nights {$output_ni}  Rooms {$output_ro} {$hidden_fields}
EOT; return $out; } $package = get_package_rate(); ?> Hotel Puri Cendana > Seminyak > Bali Hotel Accommodation


 

 

 

 

Copyright © . Hotel Puri Cendana. All Rights Reserved.

 


=pvalidity1_start && '{$CID}'<=pvalidity1_end,'1', IF('{$CID}'>=pvalidity2_start && '{$CID}'<=pvalidity2_end,'2','0')) AS 'val' FROM ablpackage WHERE org_id=';{$org[id]};' AND (('{$CID}'>=pvalidity1_start && '{$CID}'<=pvalidity1_end) || ('{$CID}'>=pvalidity2_start && '{$CID}'<=pvalidity2_end) || ('{$CID}'>=pvalidity3_start && '{$CID}'<=pvalidity3_end) || ('{$CID}'>=pvalidity4_start && '{$CID}'<=pvalidity4_end) || ('{$CID}'>=pvalidity5_start && '{$CID}'<=pvalidity5_end) ) "; //echo $sql."
"; $result = open_mysql("abldata", $sql); open_mysql("close"); if (mysql_num_rows($result) > 0) { $out .= " Package Available

"; $main_rate = true; while ($linex = mysql_fetch_array($result, MYSQL_ASSOC)) { //if ($linex[val] != "0") { //$x = "pvalidity{$linex[val]}_end"; //$sql = "SELECT *,date_format(pvalidity_end,'%b %e, %Y') AS 'tgl' FROM ablpackage_rate WHERE pcode='{$linex[pcode]}' AND pvalidity_end='{$linex[$x]}' "; $sql = "SELECT *,date_format(pvalidity_end,'%b %e, %Y') AS 'tgl' FROM ablpackage_rate WHERE pcode='{$linex[pcode]}' AND '{$CID}'>=pvalidity_start AND '{$CID}'<=pvalidity_end "; $rst = open_mysql("abldata", $sql); open_mysql("close"); $R = mysql_fetch_array($rst, MYSQL_ASSOC); $url_detail = "/bali_special_package/package_list/{$linex[id]}.html" . (($affiliate_id) ? "?affiliate_id={$affiliate_id}" : ""); $out .= ""; $out .= "
"; $out .= "

" . stripslashes($linex[pname]) . "
"; $out .= "Valid until {$R[tgl]} and based on twin sharing per person

"; $url_book = "BOOK"; $rate_single = $R["pcur"] . " " . number_format($R["prate_single"]); $rate_double = $R["pcur"] . " " . number_format($R["prate_double"]); if ($R["prate_triple"] > 0) { $rate_triple = $R["pcur"] . " " . number_format($R["prate_triple"]); } else { $rate_triple = "NOT AVAILABLE"; } $out .= "
from {$rate_double}

\n"; //} } } ###################################################################### } return $out; } function form_search_hotel_detail($main_header) { global $PHP_SELF; global $HTTP_POST_VARS; global $type; global $location; global $config_abl; global $checkin; global $nights; global $rooms; global $org; global $gmode; global $gtype; global $ghotel; global $glocation; global $grategt; global $gratelt; global $gcheckin; global $gnights; global $grooms; global $gsort; global $affiliate_id; global $gview; $hotel = $HTTP_POST_VARS["hotel"]; if ($hotel == "") { $hotel = $ghotel; } if ($hotel == "") { $hotel = "all"; } if ($hotel == "all") { $type = $HTTP_POST_VARS["type"]; if ($type == "") { $type = $gtype; } if ($type == "") { $type = "all"; } $location = $HTTP_POST_VARS["location"]; if ($location == "") { $location = $glocation; } if ($location == "") { $location = "all"; } $rate_gt = $HTTP_POST_VARS["rate-gt"]; if ($rate_gt == "") { $rate_gt = $grategt; } if ($rate_gt == "") { $rate_gt = $config_abl["default_rate_gt"]; } $rate_lt = $HTTP_POST_VARS["rate-lt"]; if ($rate_lt == "") { $rate_lt = $gratelt; } if ($rate_lt == "") { $rate_lt = $config_abl["default_rate_lt"]; } } else { $type = ""; $location = ""; $rate_gt = "all"; $rate_lt = "all"; } $nights = $HTTP_POST_VARS["nights"]; if ($nights == "") { $nights = $gnights; } if ($nights == "") { $nights = $config_abl["default_nights"]; } $rooms = $HTTP_POST_VARS["rooms"]; if ($rooms == "") { $rooms = $grooms; } if ($rooms == "") { $rooms = $config_abl["default_rooms"]; } if ($checkin == "") { $checkin = $gcheckin; } if (strlen($checkin) != 10) { $checkin = ""; } $sortby = $HTTP_POST_VARS["sortby"]; if ($sortby == "") { $sortby = $gsort; } if ($sortby == "") { $sortby = "0"; } $view = $HTTP_POST_VARS["view"]; if ($view == "") { $view = $gview; } if ($view == "") { $view = "0"; } $ID = $org["id"]; $submit_title = "Search"; $hidden_fields = ""; $form_action = "/hotel/search.html"; if ($ID != "") { $type = $org["type"]; $hotel = $org["name"]; $location = $org["city"]; $submit_title = "Check Rooms Availability"; $form_action = "/" . $type . "/" . $type . "_detail/super_saver/" . $ID . ".html"; $hidden_fields = ""; $hidden_fields .= ""; $hidden_fields .= ""; //$hidden_fields .= ""; } //$hidden_fields .= ""; //$hidden_fields .= ""; //list city dalam combo box /*$sqlcity = "SELECT DISTINCT org_city,org_state FROM organization order by org_state,org_city "; $resultcity = open_mysql("abldata", $sqlcity); $listcity = "\n"; $resultcity = open_mysql("close"); */ $sqlcity = "SELECT DISTINCT org_city,org_state,org_country FROM organization order by org_country,org_state,org_city "; $resultcity = open_mysql("abldata", $sqlcity); $listcity = "\n"; $resultcity = open_mysql("close"); $arr_type = array(0 => "hotel", 1 => "villa", 2 => "preferred", 3 => "homestay", 4 => "hotdeals", 5 => "all"); if ($type == "") { $type = "all"; } $output_type = ''; $bgcolor = "#CCCCCC"; if ($type == "hotdeals") { $bgcolor = "#CCFFCC"; } if ($checkin == "") { $tomorrow = mktime(0, 0, 0, date("m"), date("d") + $config_abl["default_start_checkin"], date("Y")); $checkin = date("Y-m-d", $tomorrow); } else { #validate the date; $checkin = date("Y-m-d", mktime(0, 0, 0, substr($checkin, 5, 2) + 0, substr($checkin, 8, 2) + 0, substr($checkin, 0, 4))); } $org["checkin"] = $checkin; $org["rooms"] = $rooms; $org["nights"] = $nights; $bln = (int)substr($checkin, 5, 2); $thn = (int)substr($checkin, 0, 4); $dt = (int)substr($checkin, 8, 2); $output_ci = ''; $output_ci .= ''; $output_ci .= ''; $output_ni = ''; $output_ro = ''; $arr_sort = array(0 => "Hits", 1 => "Name", 2 => "Room Rate", 3 => "Location", 4 => "Star"); $output_sort = ''; if ($gmode == "availability") { $view = "1"; } $arr_sava = array(0 => "All", 1 => "Instant Confirm"); $output_sava = ''; if (!$main_header) { if ($ID != "") { //check availability for hotel that selected echo <<< EOT
{$hotel}
Check In: {$output_ci} Nights: {$output_ni} Rooms: {$output_ro} {$hidden_fields}

EOT; } else { //if id == blank so nothing to display } } else { if ($ID != "") { $hotel = "all"; } echo <<< EOT
Name
Destination
{$listcity}
Check-in date
{$output_ci}
Night
{$output_ni}
Room
{$output_ro}

{$hidden_fields}
EOT; } } ?>