DbConnOpen()) echo "connection failed
".$db->DbComGetLastError()."
"; if(!$DbID->DbConnSelectDb()) echo "selection of database failed
".$db->DbComGetLastError()."
"; $ConnectArray = get_object_vars($DbID); $ConnectID = $ConnectArray[ConnectID]; // Übersetzung if (!$lang) $lang = "de"; include ("lib/lang_choose_hotel.inc.php"); // DIE HTML VARS include ("lib/html_vars.inc.php"); // DAS LAYOUT include ("lib/template.inc.php"); // SESSION AUSLESEN //include("lib/class_session.inc.php"); //$Sess = new Session; //$Sess->Read($S, $ID, $ConnectID); // FORM BAUEN require("../lib/class_form.inc.php"); // NEUES OBJEKT ERSTELLEN $sform = new Form("Searchform"); // FEHLERMELDUNGEN $sform->ERRFormfieldEmpty = ""; // Konferenzdaten holen $dbSelConference = new DbCom; if(!$dbSelConference->DbComQuery("SELECT * FROM atrConference WHERE CID=".$cid,$ConnectID)) echo "query failed
".$dbSelConference->DbComGetLastError()."
"; extract($dbSelConference ->DBComGetNextResult(),EXTR_PREFIX_ALL, "selconference"); // WELCHE Hotels GIBT ES DENN $dbRoom = new DbCom; if(!$dbRoom->DbComQuery("SELECT DISTINCT (HID) FROM atrRoom WHERE CID=".$cid,$ConnectID)) echo "query failed
".$dbRoom->DbComGetLastError()."
"; $matchingRoom = $dbRoom->DbComGetCount(); //print $matchingRoom; if ($matchingRoom == 0) { $myRows="   sorry, no Hotel available - leider kein Hotel vorhanden   "; } else { $myRows="   ".$step3gruen." ".$step3gelb." ".$step3rot."   "; for ($i=0; $i<$matchingRoom; $i++) { extract($dbRoom ->DBComGetNextResult(),EXTR_PREFIX_ALL, "room"); $dbHotel = new DbCom; if(!$dbHotel->DbComQuery("SELECT * FROM atrHotel WHERE HID=".$room_HID,$ConnectID)) echo "query failed
".$dbHotel->DbComGetLastError()."
"; $matchingHotel = $dbHotel->DbComGetCount(); for ($j=0; $j<$matchingHotel; $j++) { extract($dbHotel ->DBComGetNextResult(),EXTR_PREFIX_ALL, "hotel"); if ($lang == "en") $hotelDetail = $hotel_DetailEN; else $hotelDetail = $hotel_DetailDE; // AMPEL SCHALTEN, LINK SETZEN $myRoomCounter = 0; $dbHotelRoomAmpel = new DbCom; if(!$dbHotelRoomAmpel->DbComQuery("SELECT * FROM atrRoom WHERE HID=".$hotel_HID." AND CID=".$cid." AND AvailableRooms > 0",$ConnectID)) echo "query failed
".$dbHotelRoom->DbComGetLastError()."
"; $matchingHotelRoomAmpel = $dbHotelRoomAmpel->DbComGetCount(); for ($l=0; $l<$matchingHotelRoomAmpel; $l++) { extract($dbHotelRoomAmpel ->DBComGetNextResult(),EXTR_PREFIX_ALL, "ampel"); $myRoomCounter = $myRoomCounter + $ampel_AvailableRooms; } if ($myRoomCounter < 1) { $ampelImage = ""; $ampelLink = "".$step3noBooking."  ".$step3Booking."  "; } elseif ($myRoomCounter < $selconference_RoomLow) { $ampelImage = ""; $ampelLink = "".$step3noBooking."  ".$step3Booking."  "; } else { $ampelImage = ""; $ampelLink = "".$step3noBooking."  ".$step3Booking."  "; } // GIBT ES EIN BILD? if (($hotel_Image == "0") || ($hotel_Image == "")) $hotel_Image = "spacer.gif"; $myRows = $myRows." ".$ampelImage." ".$hotel_Name."
".$ampelLink."
".nl2br($hotelDetail). "

".$hotel_ZIP." ".$hotel_Location.", ".$hotel_Street."

"; $dbHotelRoom = new DbCom; if(!$dbHotelRoom->DbComQuery("SELECT * FROM atrRoom WHERE HID=".$hotel_HID." AND CID=".$cid,$ConnectID)) echo "query failed
".$dbHotelRoom->DbComGetLastError()."
"; $matchingHotelRoom = $dbHotelRoom->DbComGetCount(); for ($k=0; $k<$matchingHotelRoom; $k++) { extract($dbHotelRoom ->DBComGetNextResult(),EXTR_PREFIX_ALL, "hotelroom"); $myRows = $myRows."

".$hotelroom_BedNo." ".$step3Descr1." ".nl2br($hotelroom_Extra)."
".$step3Descr2.": ".$hotelroom_Price." ".$step3Descr3." ".$hotelroom_AvailableRooms." ".$step3Descr4."
".$step3Descr5." ".convertDate($hotelroom_AvailableFrom, $lang)." ".$step3Descr6." ".convertDate($hotelroom_AvailableTo, $lang)." ".$step3Descr7."

"; } $myRows = $myRows." "; } } } $mainTable = " ".$myRows."
".$selconference_Name." ".$step3From." ".convertDate($selconference_StartDate, $lang)." ".$step3To." ".convertDate($selconference_EndDate, $lang)."


"; $html = getLayout($HTML_TITLE, $step1PageTitle, $step1PageSubtitle, $step3Heading, $step3Hint, $mainTable, $FOOT_NOTE, $cid); print $html; ?>