var myJSONRatingObjectForPOI={"Hotel_Rating_AAA":[{"Display":"N/A","value":"0"},{"Display":"*","value":"1"},{"Display":"**","value":"2"},{"Display":"***","value":"3"},{"Display":"****","value":"4"},{"Display":"*****","value":"5"}],"Hotel_Rating_Michelin":[{"Display":"N/A","value":"0"},{"Display":"*","value":"1"},{"Display":"**","value":"2"},{"Display":"***","value":"3"}],"Hotel_Rating_Mobil_Travel_Guide":[{"Display":"N/A","value":"0"},{"Display":"*","value":"1"},{"Display":"**","value":"2"},{"Display":"***","value":"3"},{"Display":"****","value":"4"},{"Display":"*****","value":"5"}]};var myJSONCheckObjectForPOI={"Snow_Sports":[{"Display":"No","value":"0"},{"Display":"Downhill","value":"1"},{"Display":"Cross Country","value":"2"},{"Display":"Snowshoeing","value":"3"},{"Display":"Snowboarding","value":"4"}],"TV_Color":[{"Display":"No","value":"0"},{"Display":"With Cable/Satellite","value":"1"},{"Display":"With Cable/Satellite/Premium Channels","value":"2"},{"Display":"With VCR","value":"3"},{"Display":"With DVD","value":"4"},{"Display":"Cable Hookup","value":"5"}],"Front_Door_Services":[{"Display":"None","value":"0"},{"Display":"Porter/Bellman","value":"1"},{"Display":"Doorman","value":"2"},{"Display":"Valet","value":"3"}],"Private_Banquet_Rooms_Available":[{"Display":"No","value":"0"},{"Display":"Private","value":"1"},{"Display":"Banquet","value":"2"}],"Water_Sports":[{"Display":"No","value":"0"},{"Display":"Boating","value":"1"},{"Display":"Jetski","value":"2"},{"Display":"Canoeing","value":"3"},{"Display":"White Water Rafting","value":"4"}],"Breakfast":[{"Display":"N/A","value":"0"},{"Display":"Dining Room","value":"1"},{"Display":"Self Serve - Cold","value":"2"},{"Display":"Self-Service - Hot","value":"3"},{"Display":"Room Service","value":"4"},{"Display":"Complementary","value":"5"}],"Internet_In_Room":[{"Display":"No","value":"0"},{"Display":"Dial-up","value":"1"},{"Display":"Ethernet","value":"2"},{"Display":"Wireless","value":"3"},{"Display":"Yes","value":"4"}],"Camping_Site_Type":[{"Display":"N/A","value":"0"},{"Display":"Primitive","value":"1"},{"Display":"Gravel Site","value":"2"},{"Display":"Dirt Site","value":"3"},{"Display":"Paved Site","value":"4"},{"Display":"Grass Site","value":"5"}],"Swimming_Pool":[{"Display":"No","value":"0"},{"Display":"Indoor","value":"1"},{"Display":"Outdoor heated","value":"2"},{"Display":"Outdoor not heated","value":"3"},{"Display":"Yes","value":"4"}],"Camping_Allowed":[{"Display":"No","value":"0"},{"Display":"Backpacking","value":"1"},{"Display":"Group","value":"2"},{"Display":"Tent/Trailer","value":"3"},{"Display":"RV","value":"4"},{"Display":"Yes","value":"5"}]};var myJSONRadioObjectForPOI={"RV":[{"Display":"No","value":"0"},{"Display":"Allowed","value":"1"},{"Display":"Available for rent","value":"2"}],"Massage":[{"Display":"N/A","value":"0"},{"Display":"(Onsite)","value":"1"},{"Display":"(Offsite nearby)","value":"2"}],"Bathroom":[{"Display":"N/A","value":"0"},{"Display":"Private with tub/shower","value":"1"},{"Display":"Private with shower only","value":"2"},{"Display":"Shared with tub/shower","value":"3"},{"Display":"Shared with shower only","value":"4"},{"Display":"Shared no tub/shower","value":"5"}],"Fireplaces_Available":[{"Display":"No","value":"0"},{"Display":"(Some rooms)","value":"1"},{"Display":"(All rooms)","value":"2"}],"Internet_Wireless_In_Public_Areas":[{"Display":"No","value":"0"},{"Display":"Free","value":"1"},{"Display":"Fee","value":"2"}],"Restaurant_Dining_Room":[{"Display":"No","value":"0"},{"Display":"24 hr","value":"1"},{"Display":"Ltd service","value":"2"},{"Display":"Local delivery service","value":"3"},{"Display":"Nearby","value":"4"},{"Display":"Yes","value":"5"}],"Telephone_Special_Services":[{"Display":"N/A","value":"0"},{"Display":"In bathroom","value":"1"},{"Display":"TDD","value":"2"}],"Grill_Available_On_Site":[{"Display":"N/A","value":"0"},{"Display":"Propane","value":"1"},{"Display":"Charcoal","value":"2"}],"Tennis_Courts":[{"Display":"N/A","value":"0"},{"Display":"Onsite","value":"1"},{"Display":"Offsite nearby","value":"2"}],"Outdoor_Seating":[{"Display":"No","value":"0"},{"Display":"Yes","value":"1"},{"Display":"N/A","value":"2"}],"Refrigerator_In_Room":[{"Display":"No","value":"0"},{"Display":"Mini","value":"1"},{"Display":"Full Size","value":"2"}],"Picnic_Area":[{"Display":"","value":"0"},{"Display":"","value":"1"},{"Display":"(With Shelters)","value":"2"}],"Lodging_Available":[{"Display":"","value":"0"},{"Display":"(Onsite)","value":"1"},{"Display":"(Nearby)","value":"2"}],"Beach":[{"Display":"N/A","value":"0"},{"Display":"Adjacent","value":"1"},{"Display":"Close access","value":"2"}],"Balcony_Porch":[{"Display":"","value":"0"},{"Display":"(Open)","value":"1"},{"Display":"(Screened in)","value":"2"}],"Casino":[{"Display":"","value":"0"},{"Display":"(Onsite)","value":"1"},{"Display":"(Offsite nearby)","value":"2"}],"Conference_Rooms":[{"Display":"","value":"0"},{"Display":"(Onsite)","value":"1"},{"Display":"(Offsite nearby)","value":"2"},],"Racquetball_Courts":[{"Display":"N/A","value":"0"},{"Display":"Onsite","value":"1"},{"Display":"Offsite nearby","value":"2"}],"Scenic_View":[{"Display":"","value":"0"},{"Display":"(Partial/Some)","value":"1"},{"Display":"(All)","value":"2"}],"Shopping_Budget":[{"Display":"N/A","value":"0"},{"Display":"Onsite","value":"1"},{"Display":"Offsite nearby","value":"2"}],"Shopping_High_End":[{"Display":"N/A","value":"0"},{"Display":"Onsite","value":"1"},{"Display":"Offsite nearby","value":"2"}],"Spa":[{"Display":"N/A","value":"0"},{"Display":"Onsite","value":"1"},{"Display":"Offsite nearby","value":"2"}],"Waterfront":[{"Display":"","value":"0"},{"Display":"(Ocean)","value":"1"},{"Display":"(Lake/Pond)","value":"2"},{"Display":"(River)","value":"3"},{"Display":"(Bay)","value":"4"}],"Waterview":[{"Display":"","value":"0"},{"Display":"(Ocean)","value":"1"},{"Display":"(Lake/Pond)","value":"2"},{"Display":"(River)","value":"3"},{"Display":"(Bay)","value":"4"}],"Fitness_Center":[{"Display":"","value":"0"},{"Display":"(Onsite)","value":"1"},{"Display":"(Offsite nearby)","value":"2"}],"Free_Newspaper":[{"Display":"","value":"0"},{"Display":"(Local)","value":"1"},{"Display":"(National)","value":"2"},{"Display":"(International)","value":"3"},{"Display":"(Choice)","value":"4"},{"Display":"","value":"5"}],"Housekeeping":[{"Display":"","value":"0"},{"Display":"(Daily)","value":"1"},{"Display":"(Periodic)","value":"2"},{"Display":"(On request)","value":"3"}],"Internet_Fees_In_Room":[{"Display":"N/A","value":"0"},{"Display":"Free","value":"1"},{"Display":"Fee","value":"2"}],"Iron_Ironing_Board":[{"Display":"","value":"0"},{"Display":"(In room/unit)","value":"1"},{"Display":"(On request)","value":"2"}],"Kitchens_Available":[{"Display":"","value":"0"},{"Display":"(Mini)","value":"1"},{"Display":"(Full)","value":"2"},{"Display":"","value":"3"}],"Laundry_Services":[{"Display":"","value":"0"},{"Display":"(In room/unit)","value":"1"},{"Display":"(On request)","value":"2"},{"Display":"(Offsite nearby)","value":"3"}],"Reservations":[{"Display":"","value":"0"},{"Display":"(Accepted)","value":"1"},{"Display":"(Required)","value":"2"},{"Display":"(Recommended)","value":"3"}],"Dress_Code":[{"Display":"N/A","value":"0"},{"Display":"Formal","value":"1"},{"Display":"Business Attire","value":"2"},{"Display":"Business Casual","value":"3"},{"Display":"Casual","value":"4"},{"Display":"Beach Casual","value":"5"}],"Carry_Out":[{"Display":"","value":"0"},{"Display":"","value":"1"},{"Display":"(Curbside)","value":"2"}],"Live_Music":[{"Display":"N/A","value":"0"},{"Display":"Nightly","value":"1"},{"Display":"Weekend Only - Nights","value":"2"},{"Display":"All Meals - 7 days","value":"3"},{"Display":"All Meals - Weekends","value":"4"}],"Hairdryer_Available":[{"Display":"","value":"0"},{"Display":"(In room)","value":"1"},{"Display":"(On request)","value":"2"},{"Display":"(In public bath)","value":"3"}],"Happy_Hour_Complementary":[{"Display":"","value":"0"},{"Display":"(Drinks only)","value":"1"},{"Display":"(Drinks and Food)","value":"2"}],"Room_Service":[{"Display":"","value":"0"},{"Display":"","value":"1"},{"Display":"(24 hr)","value":"2"},{"Display":"(Ltd service)","value":"3"},{"Display":"(Local delivery service)","value":"4"},{"Display":"(Nearby)","value":"5"}],"Telephone":[{"Display":"","value":"0"},{"Display":"(Standard)","value":"1"},{"Display":"(Speakerphone)","value":"2"},{"Display":"(Phone connection)","value":"3"}]};function resetPrint(A){return false}function showPrint(I){var L=null;var C=getPortletParamStr("cmd","tripPrint");if(I=="tripsuitcaseportlet"){L=WCPV_PRINT_POP_UP_URL_FOR_TRIPSUITCASE;C=C+getPortletParamStr("viewFrom","tripSuitcase")}else{if(I=="myroadtripstuffportlet"){L=WCPV_PRINT_POP_UP_URL_FOR_MYROADTRIPSTUFF;C=C+getPortletParamStr("viewFrom","myRoadTripStuff");var H=document.getElementsByName("tripId");var G="";for(var E=0;E<H.length;E++){if(H[E].checked){G=H[E].value;break}}C=C+getPortletParamStr("tripId",G)}}var B=L;var D=0;for(var E=0;E<document.printPopup.options.length;E++){if(document.printPopup.options[E].checked){D=document.printPopup.options[E].value}}if(D=="0"){alert("Please select one of the three options before clicking on print");return false}if(D=="dayGuide"){var J=document.printPopup.day.value;C=C+getPortletParamStr("dayNumber",J)}C=C+getPortletParamStr("option",D);var A=document.printPopup.print.value;C=C+getPortletParamStr("printOption",A);var K=0;if(document.printPopup.addJournal.checked){K=1}C=C+getPortletParamStr("addJournal",K);B=B.replace("EXTRA_PARAMETERS",C);closePrintPopUp();var F=window.open(B,"Print");if(!F){popupblockerWarning();return false}}function saveTripFirst(){showModalPopUp("printAlertOuterDiv",270,80);return false}function closePOIShortDescription(){document.getElementById("pop-up").style.display="none"}function setCommand(frmName,hndName,hndValue){var str="document."+frmName+"."+hndName;eval(str).value=hndValue;str="document."+frmName;eval(str).submit()}function setPopupCommand(){var winName;args=setPopupCommand.arguments;var str="document."+args[0]+"."+args[1];eval(str).value=args[2];str="document."+args[0];if(args.length==10){winName=args[9]}else{if(args.length==12){winName=args[11]}else{winName="childWindow"}}if(args.length==11||args.length==12){openWindow("",winName,args[3],args[4],args[5],args[6],args[7],args[8],args[10])}else{if(args.length==9||args.length==10){openWindow("",winName,args[3],args[4],args[5],args[6],args[7],args[8])}else{if(args.length==8){openWindow("",winName,args[3],args[4],args[5],args[6],args[7])}else{if(args.length==7){openWindow("",winName,args[3],args[4],args[5],args[6])}else{if(args.length==5){openWindow("",winName,args[3],args[4])}else{openWindow("",winName)}}}}}eval(str).target=winName;eval(str).submit();eval(str).target=""}function Trim(C){var A=/^\s*/;var B=/\s*$/;return C.replace(A,"").replace(B,"")}function isWhiteSpace(B){var A=/^\s*$/;return A.test(B)}function isInteger(B){var A=/^\d*$/;return !isWhiteSpace(B)&&A.test(B)}function padLZero(B){var A=/^0*/;return B.replace(A,"")}function isDecimalFormat(C,A){var B=new RegExp("^((\\d){1,"+A+"}(\\.(\\d){1,2}){0,1})$");return B.test(C)}function openWindow(){var E;var A;var H;var G;var B;var C;var F;args=openWindow.arguments;if(!isInteger(args[2])){E=(window.screen.width)/2}else{E=args[2]}if(!isInteger(args[3])){A=(window.screen.height)/2}else{A=args[3]}if(!isInteger(args[4])){H=((window.screen.height)-A)/2}else{H=args[4]}if(!isInteger(args[5])){G=((window.screen.width)-E)/2}else{G=args[5]}if(args.length>=7&&!isWhiteSpace(args[6])){B=args[6]}else{B="auto"}if(args.length>=8&&!isWhiteSpace(args[7])){C=args[7]}else{C="no"}if(args.length>=9&&!isWhiteSpace(args[8])){F=args[8]}else{F="no"}var D="menubar="+F+",toolbar=no,location=no,status=no,resizable="+C+",scrollbars="+B+",width="+E+",height="+A+",left="+G+",top="+H;popupWin=window.open(args[0],args[1],D);popupWin.focus()}function cDate(C){this.intDate=0;this.intMonth=0;this.intYear=0;this.isDate=true;this.yyyymmdd="";var B=new Array(31,29,31,30,31,30,31,31,30,31,30,31);var A=Trim(C).split("/");if(A.length!=3||!isInteger(padLZero(Trim(A[0])))||!isInteger(padLZero(Trim(A[1])))||!isInteger(padLZero(Trim(A[2])))){this.isDate=false}else{this.intMonth=parseInt(padLZero(Trim(A[0])));this.intDate=parseInt(padLZero(Trim(A[1])));this.intYear=parseInt(padLZero(Trim(A[2])));if(this.intYear%4||(!(this.intYear%100)&&(this.intYear%400))){B[1]=28}if(this.intYear<1900||this.intYear>9999||this.intMonth<1||this.intMonth>12||this.intDate<1||this.intDate>B[this.intMonth-1]){this.isDate=false}else{this.yyyymmdd=""+this.intYear+(this.intMonth<10?"0"+this.intMonth:this.intMonth)+(this.intDate<10?"0"+this.intDate:this.intDate)}}}function FormatDate(){args=FormatDate.arguments;var A=new Array(13);A[1]="January";A[2]="February";A[3]="March";A[4]="April";A[5]="May";A[6]="June";A[7]="July";A[8]="August";A[9]="September";A[10]="October";A[11]="November";A[12]="December";var F=new Date(args[0]);var B=A[F.getMonth()+1];var E=F.getMonth()+1;if(E<10){E="0"+E}var C=F.getDate();if(C<10){C="0"+C}var D=F.getYear();if(D<2000){D=D+1900}if(args.length>1){if(args[1]==1){return E+"/"+C+"/"+D}if(args[1]==2){return C+"/"+E+"/"+D}if(args[1]==3){return B+" "+C+", "+D}if(args[1]==4){return B+" "+C}}else{return(F.getMonth()+1)+"/"+C+"/"+D}}function AddDays(A,B){A=Date.parse(FormatDate(A,3));A=parseInt(A,10);A=A+B*(24*60*60*1000);A=new Date(A);return A}function FormatNumber(A){if(parseFloat(A.replace(",",""))==0){return"0.00"}else{var D="";if(parseFloat(A)<1){D=padLZero(A)+""}else{D=A}var I="";var H="";var G="";var B="";var F;var E;var C;for(F=0;F<D.length;F++){if(D.charAt(F)!=","){I=I+D.charAt(F)}}D=I;if(D.length==0){return A}if(isNaN(D)){return false}if(D<0){B="-";D=padLZero(D.replace("-",""))}H=parseFloat(D)+"";F=H.indexOf(".");if(F>0){for(F=F+1;F<H.length;F++){G=G+H.charAt(F)}if(G.length==0){G="00"}else{if(G.length==1){G=G+"0"}else{if(G.length>2){if(G.substr(2,1)>=5){G=parseInt(G.substr(0,2))+1}else{G=G.substr(0,2)}}}}}else{G="00"}I="";E=0;C=0;if(H.indexOf(".")==-1){C=H.length}else{C=H.indexOf(".")}for(F=C;F>=0;F--){if(E>3){I=H.charAt(F)+","+I;E=1}else{I=H.charAt(F)+I}E++}H=I;if(H.indexOf(".")==-1){return(B+H+"."+G)}else{return(B+H+G)}}}function formatPhone(C){C=Trim(C);while(C.indexOf(" ",0)>-1){C=C.replace(" ","")}C=escape(C);while((C.indexOf("%28",0)>-1)||(C.indexOf("%29",0)>-1)||(C.indexOf("-",0)>-1)){C=C.replace("%28","");C=C.replace("%29","");C=C.replace("-","")}if(isInteger(C)&&padLZero(C).length==10){var B=padLZero(C);var A;A="(";for(i=0;i<B.length;i++){if(B.charAt(i)>="0"&&B.charAt(i)<="9"){if(A.length==4){A=A+") "}if(A.length==9){A=A+"-"}A=A+C.charAt(i)}else{if(B.charAt(i)!="-"&&B.charAt(i)!="("&&B.charAt(i)!=")"&&B.charAt(i)!=" "){return A}}}return A}if(isInteger(C)&&padLZero(C).length==11){var B=padLZero(C);var A;A="";for(i=0;i<B.length;i++){if(B.charAt(i)>="0"&&B.charAt(i)<="9"){if(A.length==1||A.length==5||A.length==9){A=A+"-"}A=A+C.charAt(i)}else{if(B.charAt(i)!="-"&&B.charAt(i)!="("&&B.charAt(i)!=")"&&B.charAt(i)!=" "){return A}}}return A}else{return false}}function formatSSN(A){A=Trim(A);while(A.indexOf("-",0)>-1){A=A.replace("-","")}if(isInteger(A)&&A.length<10){while(A.length<9){A="0"+A}return A.substr(0,3)+"-"+A.substr(3,2)+"-"+A.substr(5,4)}else{return false}}function checkEmail(B){var A=B.match(/^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i);if(!A){return false}else{return true}}if((navigator.appName=="Netscape")){}function MM_reloadPage(init){if(init==true){with(navigator){if((appName=="Netscape")&&(parseInt(appVersion)==4)){document.MM_pgW=innerWidth;document.MM_pgH=innerHeight;onresize=MM_reloadPage}}}else{if(innerWidth!=document.MM_pgW||innerHeight!=document.MM_pgH){location.reload()}}}function MM_findObj(E,D){var C,B,A;if(!D){D=document}if((C=E.indexOf("?"))>0&&parent.frames.length){D=parent.frames[E.substring(C+1)].document;E=E.substring(0,C)}if(!(A=D[E])&&D.all){A=D.all[E]}for(B=0;!A&&B<D.forms.length;B++){A=D.forms[B][E]}for(B=0;!A&&D.layers&&B<D.layers.length;B++){A=MM_findObj(E,D.layers[B].document)}if(!A&&D.getElementById){A=D.getElementById(E)}return A}function MM_showHideLayers(){var C,E,A,D,B=MM_showHideLayers.arguments;for(C=0;C<(B.length-2);C+=3){if((D=MM_findObj(B[C]))!=null){A=B[C+2];if(D.style){D=D.style;A=(A=="show")?"visible":(A=="hide")?"hidden":A}D.visibility=A}}}function createLayer(objName,newText){document.write("<div id='errorLayer' style='position:absolute; left:9px; top:12px; visibility: visible; zindex=1'></div>");if((obj=MM_findObj(objName))!=null){with(obj){if(document.layers){document.write(unescape(newText));document.close()}else{innerHTML=unescape(newText)}}}}function setErrorText(objName,newText){newText="<table><tr><td class='error'>"+newText+"</td></tr></table>";if((obj=MM_findObj(objName))!=null){with(obj){if(document.layers){document.write(unescape(newText));document.close()}else{innerHTML=unescape(newText)}}}}function MM_swapImgRestore(){var C,A,B=document.MM_sr;for(C=0;B&&C<B.length&&(A=B[C])&&A.oSrc;C++){A.src=A.oSrc}}function MM_preloadImages(){var D=document;if(D.images){if(!D.MM_p){D.MM_p=new Array()}var C,B=D.MM_p.length,A=MM_preloadImages.arguments;for(C=0;C<A.length;C++){if(A[C].indexOf("#")!=0){D.MM_p[B]=new Image;D.MM_p[B++].src=A[C]}}}}function MM_swapImage(){var D,C=0,A,B=MM_swapImage.arguments;document.MM_sr=new Array;for(D=0;D<(B.length-2);D+=3){if((A=MM_findObj(B[D]))!=null){document.MM_sr[C++]=A;if(!A.oSrc){A.oSrc=A.src}A.src=B[D+2]}}}function CallActive(A){A.className="MenuActive"}function CallInactive(A){A.className="Menuinactive"}function countryList(C,B){var A="";A=A+'<select class="listbox"  NAME="'+C+'">';A=A+'<OPTION selected ="true" VALUE="US">US</OPTION>';A=A+"</SELECT>";MM_setTextOfLayer(C,A)}function MM_findObj(E,D){var C,B,A;if(!D){D=document}if((C=E.indexOf("?"))>0&&parent.frames.length){D=parent.frames[E.substring(C+1)].document;E=E.substring(0,C)}if(!(A=D[E])&&D.all){A=D.all[E]}for(B=0;!A&&B<D.forms.length;B++){A=D.forms[B][E]}for(B=0;!A&&D.layers&&B<D.layers.length;B++){A=MM_findObj(E,D.layers[B].document)}if(!A&&D.getElementById){A=D.getElementById(E)}return A}function MM_setTextOfLayer(objName,newText){if((obj=MM_findObj(objName))!=null){with(obj){if(document.layers){document.write(unescape(newText));document.close()}else{innerHTML=(innerHTML+newText).replace("&","&amp;")}}}}function isBlank(A){if((A.length==0)||(A==null)){return true}else{return false}}function dDate(A){this.intDate=0;this.intMonth=0;this.intYear=0;this.intmmddyyyy=0;var B=(A).split(" ");var D=B[0];var C=(D).split("-");this.intDate=C[2];this.intMonth=C[1];this.intYear=C[0];this.intmmddyyyy=""+this.intMonth+"/"+this.intDate+"/"+this.intYear;return this.intmmddyyyy}function getPortletParamStr(A,B){var C="&"+A+"="+B;return C}function trim(A){return A.replace(/^\s+|\s+$/g,"")}function reset(A){if(A!=null){A.reset()}return false}var ahlf_jsCalendarObj=new Calendar(false,null,ahlf_jsOnSelect,ahlf_jsOnClose);ahlf_jsCalendarObj.weekNumbers=false;ahlf_jsCalendarObj.firstDayOfWeek=0;ahlf_jsCalendarObj.setTtDateFormat="%A, %B %e, %Y";ahlf_jsCalendarObj.setRange(2002,2020);var txtCalId;function ahlf_jsOnClick(H,D,B){txtCalId=D;ahlf_jsCalendarObj.create();var E=getCalendarDefaultDate(D,B);var F=E.intDate;var A=E.intMonth-1;var G=E.intYear;var C=null;if((G=="")||((F!="")&&(A<0))){C=new Date()}else{if(A==""){A=0}if(F==""){F=1}C=new Date(G,A,F)}ahlf_jsCalendarObj.setDate(C);ahlf_jsCalendarObj.showAtElement(document.getElementById(D),"BR")}function ahlf_jsOnClose(A){A.hide()}function ahlf_jsOnSelect(B){if(B.dateClicked){var A=B.date.getMonth()+1;document.getElementById(txtCalId).value=A+"/"+B.date.getDate()+"/"+B.date.getFullYear();B.callCloseHandler()}}function getCalendarDefaultDate(C,A){var B=document.getElementById(C).value;var E=new cDate(B);if(B!=""&&B!="mm/dd/yyyy"){E=new cDate(B)}else{if(A){var D=document.getElementById(A).value;if(D!=""&&D!="mm/dd/yyyy"){E=new cDate(D)}}}return E}function validatePOIForm(D,C){var B="";if(C=="publish"){var E=document.getElementById("publish");if(E!=null){E.value="publish"}var A=document.getElementById("poiStatus").value;if(A==2||A==0){if(CommonValidator.isBlank(document.getElementById("GeoCodeId").value)){B+=THERE_IS_NO_GEO_CODE_VALUE+NEW_LINE}}}else{if(C=="rejectDeletion"){var E=document.getElementById("rejectDeletion");if(E!=null){E.value="rejectDeletion"}}}B+=POIValidator.validatePOI(D);if(B==""){savePoi()}else{B=ERROR_INSTRUCTION+NEW_LINE+B+NEW_LINE;displayError(B);return false}}function resetPOIForm(B,A){if(B!=null){if(confirm(CONFIRM_RESET_IN_ALL_POI_TABS)){B.reset();resetPOI(B,A)}}return false}function disableTimeNeeded(){if(document.getElementById("timeNeededToVisit").checked==false){document.getElementById("timeNeededToVisitHH").disabled=false;document.getElementById("timeNeededToVisitMM").disabled=false}else{document.getElementById("timeNeededToVisitHH").disabled=true;document.getElementById("timeNeededToVisitMM").disabled=true;document.getElementById("timeNeededToVisitHH").value="";document.getElementById("timeNeededToVisitMM").value=""}}function resetPOI(B,A){set_disable_All(B.Payment_Cards[0],"Payment_Cards");subpoiLocationList(B.LocationId.value);disableTimeNeeded();setSeasonality();resetSepareKidsPriceField();resetPOIForMasterCategory(B,A);return false}function resetPOIForMasterCategory(B,A){switch(A){case 1:set_disable_All(B.Arrival_Day_Of_Week_Restriction[0],"Arrival_Day_Of_Week_Restriction");set_disable_All(B.Camping_Allowed[0],"Camping_Allowed");set_disable_All(B.Camping_Site_Type[0],"Camping_Site_Type");set_disable_All(B.Checkout_Day_Of_Week_Restriction[0],"Checkout_Day_Of_Week_Restriction");set_disable_All(B.Breakfast[0],"Breakfast");set_disable_All(B.Internet_In_Room[0],"Internet_In_Room");set_disable_All(B.TV_Color[0],"TV_Color");set_disable_All(B.Snow_Sports[0],"Snow_Sports");set_disable_All(B.Swimming_Pool[0],"Swimming_Pool");set_disable_All(B.Water_Sports[0],"Water_Sports");set_disable_All(B.Front_Door_Services[0],"Front_Door_Services");set_disable_All(B.Front_Door_Services[0],"Front_Door_Services");break;case 2:set_disable_All(B.Meals_served[0],"Meals_served");set_disable_All(B.Private_Banquet_Rooms_Available[0],"Private_Banquet_Rooms_Available");break;case 3:set_disable_All(B.Reservation_Accepted[0],"Reservation_Accepted");break;case 4:break;case 5:set_disable_All(B.Language_Of_Service[0],"Language_Of_Service");set_disable_All(B.Operations[0],"Operations");set_disable_All(B.Cable_Car_Gondola[0],"Cable_Car_Gondola");set_disable_All(B.Thrill_Rides[0],"Thrill_Rides");break;case 6:break;case 7:set_disable_All(B.Language_Of_Service[0],"Language_Of_Service");set_disable_All(B.Operations[0],"Operations");set_disable_All(B.Cable_Car_Gondola[0],"Cable_Car_Gondola");set_disable_All(B.Thrill_Rides[0],"Thrill_Rides");break;case 8:break}}function validateEventForm(C){var B="";if(C=="publish"){var A=document.getElementById("poiStatus").value;if(A==2||A==0){if(CommonValidator.isBlank(document.getElementById("GeoCodeId").value)){B+=THERE_IS_NO_GEO_CODE_VALUE+NEW_LINE}}var D=document.getElementById("publish");if(D!=null){D.value="publish"}}else{if(C=="rejectDeletion"){var D=document.getElementById("rejectDeletion");if(D!=null){D.value="rejectDeletion"}}}B+=EventValidator.validateEvent();if(B==""){saveEvent()}else{B=ERROR_INSTRUCTION+NEW_LINE+B+NEW_LINE;displayError(B);return false}}function resetEventForm(A){if(A!=null){if(confirm(CONFIRM_RESET_ALL_VALUES_IN_ALL_SIX_TABS_MAY_LOOSE_CHANGES_MADE_UNLESS_SAVED)){A.reset();resetEvent(A)}}return false}function resetEvent(A){displayshowtimes();resetSepareKidsPriceField();return false}function errorMessageValidate(){var A="";A+=RTWValidator.validateErrorMessage();if(A==""){saveErrorMessage()}else{A=ERROR_INSTRUCTION+NEW_LINE+A+NEW_LINE;removeWheelsSiteError();displayErrors(A,RTW_TARGET_ELEMENT);return false}}function searchEliminationValidate(){var A="";A+=RTWValidator.validateSearchElimination();if(A==""){createSearchElimination()}else{A=ERROR_INSTRUCTION+NEW_LINE+A+NEW_LINE;removeWheelsSiteError();displayErrors(A,RTW_TARGET_ELEMENT);return false}}function holidayValidate(){var A="";A+=RTWValidator.validateHoliday();if(A==""){saveHoliday()}else{A=ERROR_INSTRUCTION+NEW_LINE+A+NEW_LINE;removeWheelsSiteError();displayErrors(A,RTW_TARGET_ELEMENT);return false}}function regionValidate(){var A="";A+=RTWValidator.validateRegion();if(A==""){saveRegion()}else{A=ERROR_INSTRUCTION+NEW_LINE+A+NEW_LINE;removeWheelsSiteError();displayErrors(A,RTW_TARGET_ELEMENT);return false}}function resetRTWValidate(A){if(A!=null){if(confirm("This operation will reset all the form values. You may loose the changes made in any of the fields unless you Save it. Are you sure you want to continue?")){A.reset();resetRTW(A)}}return false}function resetRTW(A){return false}function removeWheelsSiteError(){var A=document.getElementById(WHEELS_SITE_ERROR_ELEMENT);if(A!=null){A.style.display="none"}}function displayErrors(B,C){var A=document.getElementById(C);if(A!=null){A.innerHTML=B}else{B.replace(NEW_LINE,"\n");alert(B)}}function removeErrors(B){var A=document.getElementById(B);if(A!=null){A.innerHTML="";A.style.display="none"}}function eBIPLogValidate(){var A="";A+=RTWValidator.validateEBIPLog();if(A==""){createEBIPLog()}else{A=ERROR_INSTRUCTION+NEW_LINE+A+NEW_LINE;removeWheelsSiteError();displayError(A);return false}}function eBIPLogRefreshValidate(){var A="";if(A==""){refreshEbipLog()}else{A=ERROR_INSTRUCTION+NEW_LINE+A+NEW_LINE;removeWheelsSiteError();displayError(A);return false}}function displayError(B){var A=document.getElementById(TARGET_ELEMENT);if(A!=null){A.innerHTML=B}else{B.replace(NEW_LINE,"\n");alert(B)}}var CommonValidator={error:"",isNotNull:function(A){return A!=null},isNull:function(A){return A==null},isNotBlank:function(A){return !this.isBlank(A)},isBlank:function(A){A.replace(/^\s+|\s+$/,"");if(A==null||A.length==0||A==""){return true}return false},isEmail:function(B){var A=B.match(/\b(^(\S+@).+((\.com)|(\.net)|(\.edu)|(\.mil)|(\.gov)|(\.org)|(\..{2,2}))$)\b/gi);if(B.indexOf(" ")>-1||B.indexOf("@")==0||B.indexOf("@")==B.length-1||B.indexOf("@")!=B.lastIndexOf("@")||B.indexOf(".@")!=-1||B.indexOf("@.")!=-1||!A){return false}else{return true}},getElementValueById:function(A){var B=document.getElementById(A);if(this.isNull(B)){return null}return this.trimString(B.value)},checkEmails:function(C,A){this.error="";var E=this.getElementValueById(C);if(this.isNotNull(E)&&this.isNotBlank(E)){var B=E.split(",");for(i=0;i<B.length;i++){var D=this.trimString(B[i]);if(this.isNotBlank(D)&&!this.isEmail(D)){this.error=A+WHITE_SPACE+CONTAINS_FORMAT_INVALID+NEW_LINE}}}return this.error},checkAbsUrl:function(B,A){this.error="";var C=this.getElementValueById(B);if(this.isNotNull(C)&&this.isNotBlank(C)){if(this.test(C,"^(news|telnet|nttp|file|http|ftp|https)://[-A-Za-z0-9\\.]+\\/?.*$")){}else{this.error=A+WHITE_SPACE+FORMAT_INVALID+NEW_LINE}}return this.error},checkPositiveInteger:function(B,A){this.error="";var C=this.getElementValueById(B);if(this.isNotNull(C)&&this.isNotBlank(C)){if(this.test(C,"^[0-9]*$")){}else{this.error=A+WHITE_SPACE+NOT_A_POSITIVE_INTEGER+NEW_LINE}}return this.error},checkPositiveIntegers:function(D,C){this.error="";var B=this.getElementValueById(D);if(this.isNotNull(B)&&this.isNotBlank(B)){var A=B.split(",");for(i=0;i<A.length;i++){var E=this.trimString(A[i]);if(this.isNotBlank(E)){if(this.test(E,"^[0-9]*$")){}else{this.error=C+WHITE_SPACE+CONTAINS_NOT_A_POSITIVE_INTEGER+NEW_LINE}}}}return this.error},checkIntegerInRange:function(D,B,A,C){this.error="";var E=this.getElementValueById(D);if(this.isNotNull(E)&&this.isNotBlank(E)){if(!isNaN(E)&&this.test(E,"^[-+]?[0-9]*$")&&!(E<A||E>C)){}else{this.error=B+WHITE_SPACE+INTEGER_OUT_OF_RANGE+WHITE_SPACE+"("+A+","+C+")"+NEW_LINE}}return this.error},checkIntegersInRange:function(F,D,A,E){this.error="";var C=this.getElementValueById(F);if(this.isNotNull(C)&&this.isNotBlank(C)){var B=C.split(",");for(i=0;i<B.length;i++){var G=this.trimString(B[i]);if(this.isNotBlank(G)){if(!isNaN(G)&&this.test(G,"^[-+]?[0-9]*$")&&!(G<A||G>E)){}else{this.error=D+WHITE_SPACE+CONTAINS_INTEGER_OUT_OF_RANGE+WHITE_SPACE+"("+A+","+E+")"+NEW_LINE}}}}return this.error},checkNumberInRange:function(D,B,A,C){this.error="";var E=this.getElementValueById(D);if(this.isNotNull(E)&&this.isNotBlank(E)){if(!isNaN(E)&&!(E<A||E>C)){}else{this.error=B+WHITE_SPACE+NUMBER_OUT_OF_RANGE+WHITE_SPACE+"("+A+","+C+")"+NEW_LINE}}return this.error},checkNumbersInRange:function(F,D,A,E){this.error="";var C=this.getElementValueById(F);if(this.isNotNull(C)&&this.isNotBlank(C)){var B=C.split(",");for(i=0;i<B.length;i++){var G=this.trimString(B[i]);if(this.isNotBlank(G)){if(!isNaN(G)&&!(G<A||G>E)){}else{this.error=D+WHITE_SPACE+CONTAINS_NUMBER_OUT_OF_RANGE+WHITE_SPACE+"("+A+","+E+")"+NEW_LINE}}}}return this.error},checkFloatingNumber:function(C,B,F,A){this.error="";var E=this.getElementValueById(C);if(this.isNotNull(E)&&this.isNotBlank(E)){var D="^-?[0-9]{"+F+"}\\.[0-9]{"+A+"}$";if(this.test(E,D)){}else{if(C=="costDownPayment"){this.error=B+WHITE_SPACE+COST_DOWN_PAYMENT_FORMAT+NEW_LINE}else{this.error=B+WHITE_SPACE+FORMAT_INVALID+NEW_LINE}}}return this.error},checkBlank:function(B,A){this.error="";var C=this.getElementValueById(B);if(this.isNotNull(C)&&this.isBlank(C)){this.error=A+WHITE_SPACE+FIELD_IS_BLANK+NEW_LINE}return this.error},checkUSPhoneFaxMobile:function(B,A){this.error="";var C=this.getElementValueById(B);if(this.isNotNull(C)&&this.isNotBlank(C)){if(this.test(C,"^[0-9]{3}-[0-9]{3}-[0-9]{4}$")){}else{this.error=A+WHITE_SPACE+CONTAINS_NOT_A_POSITIVE_INTEGER+OR+WHITE_SPACE+CONTAINS_FORMAT_INVALID+NEW_LINE}}return this.error},checkUSPhonesFaxsMobiles:function(D,C){this.error="";var B=this.getElementValueById(D);if(this.isNotNull(B)&&this.isNotBlank(B)){var A=B.split(",");for(i=0;i<A.length;i++){var E=this.trimString(A[i]);if(this.isNotBlank(E)){if(this.test(E,"^[0-9]{3}-[0-9]{3}-[0-9]{4}$")){}else{this.error=C+WHITE_SPACE+CONTAINS_NOT_A_POSITIVE_INTEGER+OR+WHITE_SPACE+CONTAINS_FORMAT_INVALID+NEW_LINE}}}}return this.error},checkAlphaNumeric:function(B,A){this.error="";var C=this.getElementValueById(B);if(this.isNotNull(C)&&this.isNotBlank(C)){if(this.test(C,"^[A-Z,a-z,0-9,\\s,\\t]*$")){}else{this.error=A+WHITE_SPACE+NOT_ALPHANUMERIC+NEW_LINE}}return this.error},checkWhereAlphaNumeric:function(B,A){this.error="";var C=this.getElementValueById(B);if(this.isNotNull(C)&&this.isNotBlank(C)){if(this.test(C,'^[A-Z,a-z,0-9,\\s,\\t,",","."]*$')){}else{this.error=A+WHITE_SPACE+NOT_ALPHANUMERIC+NEW_LINE}}return this.error},checkPostalCode:function(B,A){this.error="";var C=this.getElementValueById(B);if(this.isNotNull(C)&&this.isNotBlank(C)){if(this.test(C,"^(([0-9]{5})|([0-9]{5}-[0-9]{4}))$")){}else{this.error=A+WHITE_SPACE+NOT_A_VALID_POSTAL_CODE+NEW_LINE}}return this.error},trimString:function(C){var A=/^\s*/;var B=/\s*$/;return C.replace(A,"").replace(B,"")},checkFileTypes:function(C,B,A){this.error="";var E=this.getElementValueById(C);if(this.isNotNull(E)&&this.isNotBlank(E)){var D="";D=".("+A+")$";if(this.test(E.toLowerCase(),D)){}else{this.error=B+WHITE_SPACE+FILE_TYPE_NOT_SUPPORTED+NEW_LINE}}return this.error},checkDateFormatMMDDYYYY:function(B,A){this.error="";var C=this.getElementValueById(B);if(this.test(C,"^(0[1-9]|1[012]|[1-9])[- /.](0[1-9]|[1-9]|[12][0-9]|3[01])[- /.](19|20)[0-9]{2}$")){}else{this.error=A+WHITE_SPACE+INVALID_DATE_FORMAT+NEW_LINE}return this.error},checkDateValidityAndFormatMMDDYYYY:function(B,A){this.error="";var C=this.getElementValueById(B);if(this.isNotNull(C)&&!this.isBlank(C)){isValidDate=this.checkValidDate(C);if(!isValidDate){this.error=A+WHITE_SPACE+INVALID_DATE+NEW_LINE}}return this.error},checkValidDate:function(E){var D=0;var G=0;var F=0;var C=true;var H="";var B=new Array(31,29,31,30,31,30,31,31,30,31,30,31);var A=this.trimString(E).split("/");if(A.length!=3||!this.isInteger(this.padLZero(this.trimString(A[0])))||!this.isInteger(this.padLZero(this.trimString(A[1])))||!this.isInteger(this.padLZero(this.trimString(A[2])))){C=false}else{G=parseInt(this.padLZero(this.trimString(A[0])));D=parseInt(this.padLZero(this.trimString(A[1])));F=parseInt(this.padLZero(this.trimString(A[2])));if(F%4||(!(F%100)&&(F%400))){B[1]=28}if(F<1900||F>9999||G<1||G>12||D<1||D>B[G-1]){C=false}else{H=""+F+(G<10?"0"+G:G)+(D<10?"0"+D:D)}}return C},isWhiteSpace:function(B){var A=/^\s*$/;return A.test(B)},padLZero:function(B){var A=/^0*/;return B.replace(A,"")},isInteger:function(B){var A=/^\d*$/;return !this.isWhiteSpace(B)&&A.test(B)},dateeDifferences:function(E,D,A){this.error="";this.error+=this.checkDateFormatMMDDYYYY(E,A);this.error+=this.checkDateFormatMMDDYYYY(D,A);this.error+=this.checkDateValidityAndFormatMMDDYYYY(E,A);this.error+=this.checkDateValidityAndFormatMMDDYYYY(D,A);var C=new cDate(this.getElementValueById(E));var B=new cDate(this.getElementValueById(D));if(this.error==""&&this.isNotBlank(E)&&this.isNotBlank(D)){if(C.yyyymmdd>B.yyyymmdd){this.error=FROM_DATE_SHOULD_BE_LESS_THAN_TO_DATE+NEW_LINE}}else{this.error=""}return this.error},checkIntegerInRangeWithoutSigns:function(D,B,A,C){this.error="";var E=this.getElementValueById(D);if(this.isNotNull(E)&&this.isNotBlank(E)){if(!isNaN(E)&&this.test(E,"^[0-9]*$")&&!(E<A||E>C)){}else{this.error=B+WHITE_SPACE+INTEGER_OUT_OF_RANGE+WHITE_SPACE+"("+A+","+C+")"+NEW_LINE}}return this.error},checkSeparetKidsPrice:function(){this.error="";var C=0;var D=document.getElementById("kidsPriceRadios");if(D){var A=D.getElementsByTagName("input");if(A){for(var B=0;B<A.length;++B){if(A[B].type=="radio"&&A[B].name=="Separate_KidsPrice"){if(A[B].checked){C=A[B].value;break}}}}}if(C==1){if(document.getElementById("Separate_Kids_Prise_0_5").checked||document.getElementById("Separate_Kids_Prise_6_12").checked||document.getElementById("Separate_Kids_Prise_Teen").checked){}else{this.error=NO_CHECKBOX_IS_SELECTED+NEW_LINE}}return this.error},test:function(A,B){A=A.nodeType==1?A.value:A;return A==""||new RegExp(B).test(A)},checkSpecialCharacters:function(B,A){this.error="";var D=this.getElementValueById(B);if(this.isNotNull(D)&&this.isNotBlank(D)){if(this.test(D,"^([A-Z,a-z,0-9,/,\\s,\\t,,,.,',&,@,_]|[-])*$")){}else{this.error=A+WHITE_SPACE+CONTAINS_FORMAT_INVALID+NEW_LINE}if(this.error==""){if(this.test(D,"^[/,\\s,\\t,,,.,',&,@,_,-]*$")){this.error=A+WHITE_SPACE+CONTAINS_FORMAT_INVALID+NEW_LINE}}if(this.error==""&&D.length>0){var C=D.substring(0,1);if(this.test(C,"^[A-Z,a-z,0-9]*$")){}else{this.error=A+WHITE_SPACE+CONTAINS_FORMAT_INVALID+NEW_LINE}}}return this.error}};var numberOfActivePopUps=0;var WheelsAlerts={background:null,message:null,messageArray:new Array(),fadeTimer:0,OPACITY:51,STEPS:3,bgFadeIn:function(A,B,C){var D=WheelsAlerts.background;var E=A/B;if(C==null){C=E}if(D&&C<=A){Element.changeOpacity(D,C);C+=E;setTimeout("WheelsAlerts.bgFadeIn("+A+","+B+","+C+")",0)}},bgFadeOut:function(A,B,C){var D=WheelsAlerts.background;if(D){var E=A/B;if(C==null){C=A-E}if(C>=0){Element.changeOpacity(D,C);C-=E;setTimeout("WheelsAlerts.bgFadeOut("+A+","+B+","+C+")",0)}else{D.parentNode.removeChild(D);setSelectVisibility("visible",WheelsAlerts.message);WheelsAlerts.background=null}}},createWrapper:function(M,F,D,E){var J=document.createElement("div");var N=document.createElement("div");var L=document.createElement("table");var I=document.createElement("a");J.className="wheels-pop-up-outer";if(E){J.setAttribute("id",D+E)}J.align="center";N.className="wheels-pop-up-inner";I.innerHTML="Close";I.href="javascript:WheelsAlerts.killAlert()";L.className="wheels-pop-up-header";L.border=0;L.width="100%";L.cellSpacing=0;L.cellPadding=0;L.insertRow(0);var K=L.rows[0];K.insertCell(0);K.insertCell(1);K.insertCell(2);K.insertCell(3);K.insertCell(4);var C=K.cells[0];var H=K.cells[1];var B=K.cells[2];var A=K.cells[3];var G=K.cells[4];C.className="wheels-pop-up-minimize";C.innerHTML='<a href="javascript:void(0)" onclick="togglePopUp(\'innerdiv_popup_'+numberOfActivePopUps+"','img_popup_"+numberOfActivePopUps+'\')"><img border="0" id="img_popup_'+numberOfActivePopUps+'" title="Minimize" src="'+themeDisplay.getPathThemeImage()+'/portlet/wheels-pop-up-minimize.gif"/></a>';H.className="wheels-pop-up-title";H.width="100%";H.id=D;if(F){H.innerHTML=F}B.className="wheels-pop-up-drag";B.innerHTML='<a href="javascript:void(0)" onclick="javascript:void 1;"><img border="0" title="Drag" src="'+themeDisplay.getPathThemeImage()+'/portlet/wheels-pop-up-drag.gif"/></a>';A.className="wheels-pop-up-info";A.innerHTML='<a href="javascript:void(0)" onclick="javascript:void 1;"><img border="0" title="Info" src="'+themeDisplay.getPathThemeImage()+'/portlet/wheels-pop-up-info.gif"/></a>';G.className="wheels-pop-up-close";G.innerHTML='<a href="javascript:void(0)" onclick="WheelsAlerts.killAlert(this)"><img border="0" title="Close" src="'+themeDisplay.getPathThemeImage()+'/portlet/wheels-pop-up-close.gif"/></a>';M.setAttribute("id","innerdiv_popup_"+numberOfActivePopUps);N.appendChild(L);N.appendChild(M);J.appendChild(N);M.wrapper=J;Drag.makeDraggable(J,H);return J},createWrapperStopover:function(I,C,B){var F=document.createElement("div");var J=document.createElement("div");var H=document.createElement("table");var E=document.createElement("a");F.className="wheels-pop-up-outer";F.align="center";J.className="wheels-stopover-pop-up-inner";E.innerHTML="Close";E.href="javascript:WheelsAlerts.killAlert()";H.className="wheels-stopover-pop-up-header";H.width="100%";H.cellSpacing=0;H.cellPadding=0;H.insertRow(0);var G=H.rows[0];G.insertCell(0);G.insertCell(1);var A=G.cells[0];var D=G.cells[1];A.className="wheels-stopover-pop-up-title";A.width="100%";A.id=B;if(C){A.innerHTML=C}D.className="wheels-stopover-pop-up-close";D.innerHTML='<a href="javascript:void(0)" onclick="WheelsAlerts.killAlert(this)"><img border="0" title="Close" src="'+themeDisplay.getPathThemeImage()+'/portlet/wheels-stopover-pop-up-close.gif"/></a>';I.setAttribute("id","innerdiv_popup_"+numberOfActivePopUps);J.appendChild(H);J.appendChild(I);F.appendChild(J);I.wrapper=F;Drag.makeDraggable(F,A);return F},killAlert:function(E){if(E){var F=E;while(F.parentNode){if(F.className&&F.className.match("pop-up-outer")){break}F=F.parentNode}var A=document.getElementsByTagName("body")[0];var B=F.options;var C=null;var D=false;WheelsAlerts.remove(F);A.removeChild(F);if(WheelsAlerts.messageArray.length>0){WheelsAlerts.message=WheelsAlerts.messageArray[WheelsAlerts.messageArray.length-1];WheelsAlerts.message.style.zIndex=ZINDEX.ALERT+1;setSelectVisibility("visible",WheelsAlerts.message);C=F.background}else{WheelsAlerts.message=null;C=WheelsAlerts.background}if(C){WheelsAlerts.bgFadeOut(WheelsAlerts.OPACITY,WheelsAlerts.STEPS)}if(B&&B.onClose){B.onClose()}}},fireMessageBox:function(O){numberOfActivePopUps++;var I=document.body;if(!O){O=new Object()}var L=O.modal;var N=O.message;var H=O.height;var F=O.width;var J=O.noCenter;var K=O.title;var C=O.titleId;var E=O.isStopOver;var G=O.indx;var M=document.createElement("div");M.align="left";var B=null;if(E){B=WheelsAlerts.createWrapperStopover(M,K,C)}else{B=WheelsAlerts.createWrapper(M,K,C,G)}B.style.position="absolute";B.style.top=0;B.style.left=0;B.style.zIndex=ZINDEX.ALERT+1;B.options=O;if(N){M.innerHTML=N}else{M.innerHTML='<div class="portlet-loading"></div>'}if(H){if(is_ie){M.style.height=H+"px"}else{M.style.minHeight=H+"px"}}if(F){B.style.width=F+"px"}if(!WheelsAlerts.background&&L){var A=document.createElement("div");A.id="alert-message";A.style.position="absolute";A.style.top="0";A.style.left="0";A.style.zIndex=ZINDEX.ALERT;WheelsAlerts.background=A;B.background=A;A.style.backgroundColor="#000000";Element.changeOpacity(A,0);I.appendChild(A);WheelsAlerts.bgFadeIn(WheelsAlerts.OPACITY,WheelsAlerts.STEPS)}setSelectVisibility("hidden");if(WheelsAlerts.messageArray.length>0){var D=WheelsAlerts.messageArray[WheelsAlerts.messageArray.length-1];D.style.zIndex=ZINDEX.ALERT-1;setSelectVisibility("hidden",D)}setSelectVisibility("visibile",M);WheelsAlerts.message=M;WheelsAlerts.messageArray.push(B);WheelsAlerts.resize();Event.observe(window,"resize",WheelsAlerts.resize);if(J){WheelsAlerts.center()}else{WheelsAlerts.center(H,F)}Event.observe(window,"resize",WheelsAlerts.center);I.appendChild(B);window.focus();return M},popupIframe:function(B,A){if(!A){A=new Object()}var F=A.height;var E=A.width;var D=WheelsAlerts.fireMessageBox(A);var C=document.createElement("iframe");D.height="";C.src=B;C.frameBorder=0;if(E){C.style.width="100%"}D.appendChild(C);if(!A.noCenter){WheelsAlerts.center(F,E)}return D},center:function(B,C){if(WheelsAlerts.message){var D=WheelsAlerts.message.wrapper;var A=document.getElementsByTagName("body")[0];var G=D.centerMode;if(!G){if(B&&C){G=D.centerMode="xy"}else{if(B&&!C){G=D.centerMode="y"}else{if(!B&&C){G=D.centerMode="x"}else{G=D.centerMode="none"}}}}C=C||D.offsetWidth;B=B||D.offsetHeight;var F;var E;if(!is_safari){var F=(A.clientWidth-C)/2;var E=A.scrollTop+((A.clientHeight-B)/2)}else{var F=(A.offsetWidth-C)/2;var E=(A.offsetHeight-B)/2}if(G=="xy"||G=="y"){D.style.top=E+"px"}else{D.style.top=(A.scrollTop+20)+"px"}if(G=="xy"||G=="x"){D.style.left=F+"px"}else{D.style.left="20px"}}},resize:function(){if(WheelsAlerts.background){var C=WheelsAlerts.background;var A=document.getElementsByTagName("body")[0];if(!is_safari){var D=A.scrollHeight;var B=A.clientHeight;C.style.height=(D>B?D:B)+"px";C.style.width="100%"}else{C.style.height=A.offsetHeight+"px";C.style.width=A.offsetWidth+"px"}}},resizeIframe:function(A){if(WheelsAlerts.message&&A){var B=WheelsAlerts.message.getElementsByTagName("iframe")[0];var C=document.getElementsByClassName("portlet-loading",WheelsAlerts.message);if(C.length>0){C[0].parentNode.removeChild(C[0])}if(B){if(A.height){B.height=A.height}if(A.width){B.width=A.width}}}WheelsAlerts.resize()},remove:function(C){var A=WheelsAlerts.messageArray;for(var B=0;B<A.length;B++){if(A[B]==C){A.splice(B,1);break}}}};function togglePopUp(A,B){var C=document.getElementById(A);if(!C){return true}if(C.style.display=="none"){document.getElementById(B).src="/html/themes/wheels/images/portlet/wheels-pop-up-minimize.gif";document.getElementById(B).title="Minimize";C.style.display="block"}else{document.getElementById(B).src="/html/themes/wheels/images/portlet/wheels-pop-up-restore.gif";document.getElementById(B).title="Restore";C.style.display="none"}return true}var stopOverPopUp=null;function hideVerticalScroolBars(B,A){obj=document.getElementById(A);if(obj!=null){obj.style.overflow=B}}function Range(){this._value=0;this._minimum=0;this._maximum=100;this._extent=0;this._isChanging=false}Range.prototype.setValue=function(A){A=Math.round(parseFloat(A));if(isNaN(A)){return }if(this._value!=A){if(A+this._extent>this._maximum){this._value=this._maximum-this._extent}else{if(A<this._minimum){this._value=this._minimum}else{this._value=A}}if(!this._isChanging&&typeof this.onchange=="function"){this.onchange()}}};Range.prototype.getValue=function(){return this._value};Range.prototype.setExtent=function(A){if(this._extent!=A){if(A<0){this._extent=0}else{if(this._value+A>this._maximum){this._extent=this._maximum-this._value}else{this._extent=A}}if(!this._isChanging&&typeof this.onchange=="function"){this.onchange()}}};Range.prototype.getExtent=function(){return this._extent};Range.prototype.setMinimum=function(A){if(this._minimum!=A){var B=this._isChanging;this._isChanging=true;this._minimum=A;if(A>this._value){this.setValue(A)}if(A>this._maximum){this._extent=0;this.setMaximum(A);this.setValue(A)}if(A+this._extent>this._maximum){this._extent=this._maximum-this._minimum}this._isChanging=B;if(!this._isChanging&&typeof this.onchange=="function"){this.onchange()}}};Range.prototype.getMinimum=function(){return this._minimum};Range.prototype.setMaximum=function(B){if(this._maximum!=B){var A=this._isChanging;this._isChanging=true;this._maximum=B;if(B<this._value){this.setValue(B-this._extent)}if(B<this._minimum){this._extent=0;this.setMinimum(B);this.setValue(this._maximum)}if(B<this._minimum+this._extent){this._extent=this._maximum-this._minimum}if(B<this._value+this._extent){this._extent=this._maximum-this._value}this._isChanging=A;if(!this._isChanging&&typeof this.onchange=="function"){this.onchange()}}};Range.prototype.getMaximum=function(){return this._maximum};function Timer(A){this._pauseTime=typeof A=="undefined"?1000:A;this._timer=null;this._isStarted=false}Timer.prototype.start=function(){if(this.isStarted()){this.stop()}var A=this;this._timer=window.setTimeout(function(){if(typeof A.ontimer=="function"){A.ontimer()}},this._pauseTime);this._isStarted=false};Timer.prototype.stop=function(){if(this._timer!=null){window.clearTimeout(this._timer)}this._isStarted=false};Timer.prototype.isStarted=function(){return this._isStarted};Timer.prototype.getPauseTime=function(){return this._pauseTime};Timer.prototype.setPauseTime=function(A){this._pauseTime=A};Slider.isSupported=typeof document.createElement!="undefined"&&typeof document.documentElement!="undefined"&&typeof document.documentElement.offsetWidth=="number";function Slider(B,D,C){if(!B){return }this._orientation=C||"horizontal";this._range=new Range();this._range.setExtent(0);this._blockIncrement=10;this._unitIncrement=1;this._timer=new Timer(100);if(Slider.isSupported&&B){this.document=B.ownerDocument||B.document;this.element=B;this.element.slider=this;this.element.unselectable="on";this.element.className=this._orientation+" "+this.classNameTag+" "+this.element.className;this.line=this.document.createElement("DIV");this.line.className="line";this.line.unselectable="on";this.line.appendChild(this.document.createElement("DIV"));this.element.appendChild(this.line);this.handle=this.document.createElement("DIV");this.handle.className="handle";this.handle.unselectable="on";this.handle.appendChild(this.document.createElement("DIV"));this.handle.firstChild.appendChild(this.document.createTextNode(String.fromCharCode(160)));this.element.appendChild(this.handle)}this.input=D;var A=this;this._range.onchange=function(){A.recalculate();if(typeof A.onchange=="function"){A.onchange()}};if(Slider.isSupported&&B){this.element.onfocus=Slider.eventHandlers.onfocus;this.element.onblur=Slider.eventHandlers.onblur;this.element.onmousedown=Slider.eventHandlers.onmousedown;this.element.onmouseover=Slider.eventHandlers.onmouseover;this.element.onmouseout=Slider.eventHandlers.onmouseout;this.element.onkeydown=Slider.eventHandlers.onkeydown;this.element.onkeypress=Slider.eventHandlers.onkeypress;this.element.onmousewheel=Slider.eventHandlers.onmousewheel;this.handle.onselectstart=this.element.onselectstart=function(){return false};this._timer.ontimer=function(){A.ontimer()};window.setTimeout(function(){A.recalculate()},1)}else{this.input.onchange=function(E){A.setValue(A.input.value)}}}Slider.eventHandlers={getEvent:function(B,A){if(!B){if(A){B=A.document.parentWindow.event}else{B=window.event}}if(!B.srcElement){var A=B.target;while(A!=null&&A.nodeType!=1){A=A.parentNode}B.srcElement=A}if(typeof B.offsetX=="undefined"){B.offsetX=B.layerX;B.offsetY=B.layerY}return B},getDocument:function(A){if(A.target){return A.target.ownerDocument}return A.srcElement.document},getSlider:function(B){var A=B.target||B.srcElement;while(A!=null&&A.slider==null){A=A.parentNode}if(A){return A.slider}return null},getLine:function(B){var A=B.target||B.srcElement;while(A!=null&&A.className!="line"){A=A.parentNode}return A},getHandle:function(C){var B=C.target||C.srcElement;var A=/handle/;while(B!=null&&!A.test(B.className)){B=B.parentNode}return B},onfocus:function(B){var A=this.slider;A._focused=true},onblur:function(B){var A=this.slider;A._focused=false},onmouseover:function(A){A=Slider.eventHandlers.getEvent(A,this)},onmouseout:function(A){A=Slider.eventHandlers.getEvent(A,this)},onmousedown:function(D){D=Slider.eventHandlers.getEvent(D,this);var A=this.slider;if(A.element.focus){A.element.focus()}Slider._currentInstance=A;var C=A.document;if(C.addEventListener){C.addEventListener("mousemove",Slider.eventHandlers.onmousemove,true);C.addEventListener("mouseup",Slider.eventHandlers.onmouseup,true)}else{if(C.attachEvent){C.attachEvent("onmousemove",Slider.eventHandlers.onmousemove);C.attachEvent("onmouseup",Slider.eventHandlers.onmouseup);C.attachEvent("onlosecapture",Slider.eventHandlers.onmouseup);A.element.setCapture()}}if(Slider.eventHandlers.getHandle(D)){Slider._sliderDragData={screenX:D.screenX,screenY:D.screenY,dx:D.screenX-A.handle.offsetLeft,dy:D.screenY-A.handle.offsetTop,startValue:A.getValue(),slider:A}}else{var B=Slider.eventHandlers.getLine(D);A._mouseX=D.offsetX+(B?A.line.offsetLeft:0);A._mouseY=D.offsetY+(B?A.line.offsetTop:0);A._increasing=null;A.ontimer()}},onmousemove:function(F){F=Slider.eventHandlers.getEvent(F,this);if(Slider._sliderDragData){var C=Slider._sliderDragData.slider;var A=C.getMaximum()-C.getMinimum();var B,G,E;if(C._orientation=="horizontal"){B=C.element.offsetWidth-C.handle.offsetWidth;G=F.screenX-Slider._sliderDragData.dx;E=Math.abs(F.screenY-Slider._sliderDragData.screenY)>100}else{B=C.element.offsetHeight-C.handle.offsetHeight;G=C.element.offsetHeight-C.handle.offsetHeight-(F.screenY-Slider._sliderDragData.dy);E=Math.abs(F.screenX-Slider._sliderDragData.screenX)>100}C.setValue(E?Slider._sliderDragData.startValue:C.getMinimum()+A*G/B);return false}else{var C=Slider._currentInstance;if(C!=null){var D=Slider.eventHandlers.getLine(F);C._mouseX=F.offsetX+(D?C.line.offsetLeft:0);C._mouseY=F.offsetY+(D?C.line.offsetTop:0)}}},onmouseup:function(C){C=Slider.eventHandlers.getEvent(C,this);var A=Slider._currentInstance;var B=A.document;if(B.removeEventListener){B.removeEventListener("mousemove",Slider.eventHandlers.onmousemove,true);B.removeEventListener("mouseup",Slider.eventHandlers.onmouseup,true)}else{if(B.detachEvent){B.detachEvent("onmousemove",Slider.eventHandlers.onmousemove);B.detachEvent("onmouseup",Slider.eventHandlers.onmouseup);B.detachEvent("onlosecapture",Slider.eventHandlers.onmouseup);A.element.releaseCapture()}}if(Slider._sliderDragData){Slider._sliderDragData=null}else{A._timer.stop();A._increasing=null}Slider._currentInstance=null},onkeydown:function(C){C=Slider.eventHandlers.getEvent(C,this);var B=this.slider;var A=C.keyCode;switch(A){case 33:B.setValue(B.getValue()+B.getBlockIncrement());break;case 34:B.setValue(B.getValue()-B.getBlockIncrement());break;case 35:B.setValue(B.getOrientation()=="horizontal"?B.getMaximum():B.getMinimum());break;case 36:B.setValue(B.getOrientation()=="horizontal"?B.getMinimum():B.getMaximum());break;case 38:case 39:B.setValue(B.getValue()+B.getUnitIncrement());break;case 37:case 40:B.setValue(B.getValue()-B.getUnitIncrement());break}if(A>=33&&A<=40){return false}},onkeypress:function(B){B=Slider.eventHandlers.getEvent(B,this);var A=B.keyCode;if(A>=33&&A<=40){return false}},onmousewheel:function(B){B=Slider.eventHandlers.getEvent(B,this);var A=this.slider;if(A._focused){A.setValue(A.getValue()+B.wheelDelta/120*A.getUnitIncrement());return false}}};Slider.prototype.classNameTag="dynamic-slider-control",Slider.prototype.setValue=function(A){this._range.setValue(A);this.input.value=this.getValue()};Slider.prototype.setOppositeValue=function(A){this._range.setValue(-1*A);this.input.value=this.getValue()};Slider.prototype.getAbsValue=function(){return Math.abs(this.getValue())};Slider.prototype.getValue=function(){return this._range.getValue()};Slider.prototype.setMinimum=function(A){this._range.setMinimum(A);this.input.value=this.getValue()};Slider.prototype.getMinimum=function(){return this._range.getMinimum()};Slider.prototype.setMaximum=function(A){this._range.setMaximum(A);this.input.value=this.getValue()};Slider.prototype.getMaximum=function(){return this._range.getMaximum()};Slider.prototype.setUnitIncrement=function(A){this._unitIncrement=A};Slider.prototype.getUnitIncrement=function(){return this._unitIncrement};Slider.prototype.setBlockIncrement=function(A){this._blockIncrement=A};Slider.prototype.getBlockIncrement=function(){return this._blockIncrement};Slider.prototype.getOrientation=function(){return this._orientation};Slider.prototype.setOrientation=function(A){if(A!=this._orientation){if(Slider.isSupported&&this.element){this.element.className=this.element.className.replace(this._orientation,A)}this._orientation=A;this.recalculate()}};Slider.prototype.recalculate=function(){if(!Slider.isSupported||!this.element){return }var C=this.element.offsetWidth;var E=this.element.offsetHeight;var A=this.handle.offsetWidth;var D=this.handle.offsetHeight;var F=this.line.offsetWidth;var B=this.line.offsetHeight;if(this._orientation=="horizontal"){this.handle.style.left=(C-A)*(this.getValue()-this.getMinimum())/(this.getMaximum()-this.getMinimum())+"px";this.handle.style.top=(E-D)/2+"px";this.line.style.top=(E-B)/2+"px";this.line.style.left=A/2+"px";this.line.style.width=Math.max(0,C-A-2)+"px";if(this.line.firstChild){this.line.firstChild.style.width=Math.max(0,C-A-4)+"px"}}else{this.handle.style.left="2px";this.handle.style.top=E-D-(E-D)*(this.getValue()-this.getMinimum())/(this.getMaximum()-this.getMinimum())+"px";this.line.style.left="9px";this.line.style.top=D/2+"px";this.line.style.height=Math.max(0,E-D-2)+"px";if(this.line.firstChild){this.line.firstChild.style.height=Math.max(0,E-D-4)+"px"}}};Slider.prototype.ontimer=function(){var B=this.handle.offsetWidth;var D=this.handle.offsetHeight;var A=this.handle.offsetLeft;var C=this.handle.offsetTop;if(this._orientation=="horizontal"){if(this._mouseX>A+B&&(this._increasing==null||this._increasing)){this.setValue(this.getValue()+this.getBlockIncrement());this._increasing=true}else{if(this._mouseX<A&&(this._increasing==null||!this._increasing)){this.setValue(this.getValue()-this.getBlockIncrement());this._increasing=false}}}else{if(this._mouseY>C+D&&(this._increasing==null||!this._increasing)){this.setValue(this.getValue()-this.getBlockIncrement());this._increasing=false}else{if(this._mouseY<C&&(this._increasing==null||this._increasing)){this.setValue(this.getValue()+this.getBlockIncrement());this._increasing=true}}}this._timer.start()};function doSubmit(F,B){b_submit=true;if(document.getElementById("airTripType").disabled==false){if((document.getElementById("leavingFrom").value.length<3)||(document.getElementById("leavingFrom").value.length>25)){b_submit=false;cDisplay("errormsg,inline","airportmsg,inline","minoragemsg,none");document.getElementById("leavingFrom").focus();return }if((document.getElementById("goingTo").value.length<3)||(document.getElementById("goingTo").value.length>25)){b_submit=false;cDisplay("errormsg,inline","airportmsg,inline","minoragemsg,none");document.getElementById("goingTo").focus();return }var D="&src="+F+"&src_aid="+B;D=D+"&leavingFrom="+document.getElementById("leavingFrom").value;D=D+"&goingTo="+document.getElementById("goingTo").value;D=D+"&dateLeavingMonth="+document.getElementById("AIR_frommonth").value;D=D+"&dateLeavingDay="+document.getElementById("AIR_fromdate").value;D=D+"&dateLeavingTime="+document.getElementById("datelt").value;D=D+"&dateReturningMonth="+document.getElementById("AIR_tomonth").value;D=D+"&dateReturningDay="+document.getElementById("AIR_todate").value;D=D+"&dateReturningTime="+document.getElementById("datert").value;D=D+"&adults="+document.getElementById("FO_adults").selectedIndex;D=D+"&children="+document.getElementById("FO_children").selectedIndex;D=D+"&seniors="+document.getElementById("FO_seniors").selectedIndex;var C="/nexres/start-pages/gateway.cgi?action=search&engine=customtrip"+D;document.AirSearchForm.action=C}else{var E;if(document.AirSearchForm.flightType.value==undefined){for(var A=0;A<document.AirSearchForm.flightType.length;++A){if(document.AirSearchForm.flightType[A].checked){E=document.AirSearchForm.flightType[A].value;break}}}else{E=document.AirSearchForm.flightType.value}if(document.getElementById("cb_nba_input").checked==true){document.getElementById("cb_nba_input").value="on"}else{document.getElementById("cb_nba_input").value="off"}if(E=="multicity"){if((document.getElementById("leavingFrom1").value.length<3)||(document.getElementById("leavingFrom1").value.length>25)){b_submit=false;cDisplay("errormsg,inline","airportmsg,inline","minoragemsg,none");document.getElementById("leavingFrom1").focus();return }if((document.getElementById("goingTo1").value.length<3)||(document.getElementById("goingTo1").value.length>25)){b_submit=false;cDisplay("errormsg,inline","airportmsg,inline","minoragemsg,none");document.getElementById("goingTo1").focus();return }if((document.getElementById("leavingFrom2").value.length<3)||(document.getElementById("leavingFrom2").value.length>25)){b_submit=false;cDisplay("errormsg,inline","airportmsg,inline","minoragemsg,none");document.getElementById("leavingFrom2").focus();return }if((document.getElementById("goingTo2").value.length<3)||(document.getElementById("goingTo2").value.length>25)){b_submit=false;cDisplay("errormsg,inline","airportmsg,inline","minoragemsg,none");document.getElementById("goingTo2").focus();return }document.getElementById("leavingDate1").value=getDate(document.getElementById("AIR_frommonth1").value,document.getElementById("AIR_fromdate1").value);document.getElementById("leavingDate2").value=getDate(document.getElementById("AIR_frommonth2").value,document.getElementById("AIR_fromdate2").value);if((document.getElementById("leavingFrom3").value)&&(document.getElementById("goingTo3").value)){document.getElementById("leavingDate3").value=getDate(document.getElementById("AIR_frommonth3").value,document.getElementById("AIR_fromdate3").value)}else{document.getElementById("leavingDate3").value=""}if((document.getElementById("leavingFrom4").value)&&(document.getElementById("goingTo4").value)){document.getElementById("leavingDate4").value=getDate(document.getElementById("AIR_frommonth4").value,document.getElementById("AIR_fromdate4").value)}else{document.getElementById("leavingDate4").value=""}}else{if((document.getElementById("leavingFrom").value.length<3)||(document.getElementById("leavingFrom").value.length>25)){b_submit=false;cDisplay("errormsg,inline","airportmsg,inline","minoragemsg,none");document.getElementById("leavingFrom").focus();return }if((document.getElementById("goingTo").value.length<3)||(document.getElementById("goingTo").value.length>25)){b_submit=false;cDisplay("errormsg,inline","airportmsg,inline","minoragemsg,none");document.getElementById("goingTo").focus();return }document.getElementById("leavingDate").value=getDate(document.getElementById("AIR_frommonth").value,document.getElementById("AIR_fromdate").value);if(E=="roundtrip"){document.getElementById("returningDate").value=getDate(document.getElementById("AIR_tomonth").value,document.getElementById("AIR_todate").value)}}}for(var A=1;A<=document.getElementById("FO_children").selectedIndex;++A){if(document.getElementById("FO_child"+A).selectedIndex==0){b_submit=false;cDisplay("errormsg,inline","airportmsg,none","minoragemsg,inline");document.getElementById("FO_child"+A).focus();return }}cDisplay("errormsg,none");document.AirSearchForm.submit()}function airOpenCalRel(A,J,E,B,K,F,I,H,G){var D;for(var C=0;C<document.AirSearchForm.flightType.length;++C){if(document.AirSearchForm.flightType[C].checked){D=document.AirSearchForm.flightType[C].value;break}}if(D=="oneway"){openCalRel(A,J,J,B,K,F,I,H,G)}else{openCalRel(A,J,E,B,K,F,I,H,G)}}function changeSearchType(B,A){var C=document.AirSearchForm;switch(B.value){case"roundtrip":cDisplay("datedf,none","daterf,none");cDisplay("roundtripdate,inline","roundtripdest,inline","returnTime,inline","plusminisDate,inline");if(A!="dest"){cDisplay("multiCityForm,none");cDisplay("cb_air_nba,inline")}break;case"oneway":cDisplay("roundtripdate,inline","roundtripdest,inline","datelt,inline","datert,inline");cDisplay("returnTime,none","plusminisDate,none","datedf,none","daterf,none");C.dateTypeSelect[0].checked=true;if(A!="dest"){document.getElementById("cb_nba_input").value="off";document.getElementById("cb_nba_input").checked=false;cDisplay("multiCityForm,none","cb_air_nba,none")}break;case"multicity":document.getElementById("cb_nba_input").value="off";document.getElementById("cb_nba_input").checked=false;cDisplay("multiCityForm,inline","datelt,inline","datert,inline");cDisplay("roundtripdate,none","roundtripdest,none");C.dateTypeSelect[0].checked=true;break;default:}}function dispAdvOpt(C){var A=C.split("|");var B=document.getElementById(A[1]);o_otherImg=(B.id=="airNorgie")?document.getElementById("typNorgie"):document.getElementById("airNorgie");if(B.src.indexOf("show")=="-1"){if(B.id=="airNorgie"){cDisplay("advAirOpt,none")}else{cDisplay("advTypOpt,none")}B.src="http://hg.travelocity.com.edgesuite.net/graphics/icon_show.gif"}else{if((B.src.indexOf("show")!="-1")){if(B.id=="airNorgie"){cDisplay("advAirOpt,inline")}else{cDisplay("advTypOpt,inline")}B.src="http://hg.travelocity.com.edgesuite.net/graphics/icon_hide.gif"}}}function updateButton(){var C;for(var A=0;A<document.AirSearchForm.flightType.length;++A){if(document.AirSearchForm.flightType[A].checked){C=document.AirSearchForm.flightType[A].value;break}}var B;for(var A=0;A<document.AirSearchForm.dateTypeSelect.length;++A){if(document.AirSearchForm.dateTypeSelect[A].checked){B=document.AirSearchForm.dateTypeSelect[A].value;break}}if((document.getElementById("typNorgie").src.indexOf("show")!="-1")&&(document.getElementById("airNorgie").src.indexOf("show")!="-1")&&(document.getElementById("cb_nba_input").checked==false)&&(B=="exactDates")&&(C=="roundtrip")){cDisplay("twobuttons,inline");cDisplay("onebutton,none")}else{cDisplay("twobuttons,none");cDisplay("onebutton,inline")}}function getDate(A,F){var E=new Date;var C=E.getYear();var D=E.getMonth();var B=E.getDate();if(A<(D+1)){C=C+1}if(A==(D+1)&&F<B){C=C+1}C=(C%1900)+1900;return(A+"/"+F+"/"+C)}function compareDates(C,B){var G,F;var A,H;var E,D;A=C.substring(0,C.indexOf("/"));G=C.substring(C.indexOf("/")+1,C.lastIndexOf("/"));E=C.substring(C.lastIndexOf("/")+1,C.length);H=B.substring(0,B.indexOf("/"));F=B.substring(B.indexOf("/")+1,B.lastIndexOf("/"));D=B.substring(B.lastIndexOf("/")+1,B.length);if(E>D){return 1}else{if(E<D){return -1}else{if(A>H){return 1}else{if(A<H){return -1}else{if(G>F){return 1}else{if(G<F){return -1}else{return 0}}}}}}}function cb_airDateType(B,A,C){switch(B.value){case"exactDates":cDisplay("datedf,none","daterf,none");cDisplay("datelt,inline","datert,inline");if(A!="dest"){cDisplay("cb_air_nba,inline")}if(C==1){cDisplay("cb_adv_class,inline")}break;case"plusMinusDates":cDisplay("datedf,inline","daterf,inline");cDisplay("datelt,none","datert,none");if(A!="dest"){document.getElementById("cb_nba_input").value="off";document.getElementById("cb_nba_input").checked=false;cDisplay("cb_air_nba,none")}if(C==1){cDisplay("cb_adv_class,none")}break;default:}}function cDisplay(){a_args=cDisplay.arguments;for(var A=0;A<a_args.length;A++){a_items=a_args[A].split(",");document.getElementById(a_items[0]).style.display=a_items[1]}}function childAges(B,C){o_div=document.getElementById(C);if(B.selectedIndex!=0){a_children=o_div.getElementsByTagName("div");o_div.style.display="block";for(i=0;i<a_children.length;i++){a_children[i].style.visibility=(i<B.selectedIndex)?"visible":"hidden"}}else{for(i=1;i<=a_children.length;i++){var A="FO_child"+i;document.getElementById(A).value=1}o_div.style.display="none"}}var dateArray=new Array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec");function getTodaysMonth(){return dateArray[(new Date()).getMonth()]}function checkForFlexibleDates(){var D=document.location.href;if(D.indexOf("flexibleDates")!=-1){var G=D.substr(D.indexOf("departure_dt"),16);var A=D.substr(D.indexOf("arrival_dt"),14);var C=document.AirSearchForm.departure_dt;var B=document.AirSearchForm.arrival_dt;var E="";for(var F=0;F<dateArray.length;F++){if(dateArray[F]==G.substr(G.indexOf("=")+1,3)){C.options[F+1].selected=true;break}}for(var F=0;F<dateArray.length;F++){if(dateArray[F]==A.substr(A.indexOf("=")+1,3)){B.options[F].selected=true;break}}if(E.length>3){C.options[0].selected=true}}}function fillDates(){fillDepDt();fillArrDt();checkForFlexibleDates()}function fillDepDt(){var B=document.AirSearchForm.departure_dt;var C=getTodaysMonth()+"|today";B.options[0]=new Option("Today",C);B.options[0].selected=true;for(var A=0;A<dateArray.length;A++){B.options[B.options.length]=new Option(dateArray[B.options.length-1],dateArray[B.options.length-1])}}function fillArrDt(){var B=document.AirSearchForm.arrival_dt;for(var A=0;A<dateArray.length;A++){B.options[B.options.length]=new Option(dateArray[B.options.length],dateArray[B.options.length])}setArrDt()}function setArrDt(){var B=document.AirSearchForm.departure_dt;var D=B.selectedIndex;if(D==0){selDepDtVal=B.options[0].value;if(selDepDtVal.length>3){selDepDtVal=getTodaysMonth()}for(var A=0;A<dateArray.length;A++){if(dateArray[A]==selDepDtVal){D=A;break}}}else{D=D-1}if(D>7){D=D-8}else{D=D+4}var C=document.AirSearchForm.arrival_dt;C.options[D].selected=true}var o_popurl="#";var o_popwindow=0;var b_popwindow=1;function checkpopUp(){b_popwindow=(o_popwindow)?o_popwindow.closed:1;if(b_popwindow){document.location=o_popurl}else{o_popwindow.focus()}}function popUp(B,C,A){o_popurl=B;o_popwindow=window.open(B,C,A);setTimeout("checkpopUp()",500)}function setFilterStops(){if(document.AirSearchForm.maxConnections.checked){document.AirSearchForm.filterStops.value="0"}else{document.AirSearchForm.filterStops.value=""}}function unHiderPick(){var A=document.getElementById("where");if(A.value=="airport"){document.getElementById("airport").style.display="block";document.getElementById("address").style.display="none";document.getElementById("poi").style.display="none"}if(A.value=="address"){document.getElementById("airport").style.display="none";document.getElementById("address").style.display="block";document.getElementById("poi").style.display="none"}if(A.value=="poi"){document.getElementById("airport").style.display="none";document.getElementById("address").style.display="none";document.getElementById("poi").style.display="block"}}function dropOff(){var A=document.getElementById("diff").checked;if(A){document.getElementById("dropoff_diff").style.display="block"}else{document.getElementById("dropoff_diff").style.display="none"}}function discountHide(){var A=document.getElementById("companypref").checked;if(A){document.getElementById("discounts").style.display="block";document.getElementById("couptitle").style.display="block";document.getElementById("coupfield").style.display="block"}else{document.getElementById("discounts").style.display="none";document.getElementById("couptitle").style.display="none";document.getElementById("coupfield").style.display="none"}}function unHiderDrop(){var A=document.getElementById("dwhere");if(A.value=="doairport"){document.getElementById("dairport").style.display="block";document.getElementById("daddress").style.display="none";document.getElementById("dpoi").style.display="none"}if(A.value=="doaddress"){document.getElementById("dairport").style.display="none";document.getElementById("daddress").style.display="block";document.getElementById("dpoi").style.display="none"}if(A.value=="dopoi"){document.getElementById("dairport").style.display="none";document.getElementById("daddress").style.display="none";document.getElementById("dpoi").style.display="block"}}function change(B,A){identity=document.getElementById(B);identity.className=A}function show(A){document.getElementById(A).style.display="block"}function showInline(A){document.getElementById(A).style.display="inline"}function hide(A){document.getElementById(A).style.display="none"}function newWindow(A){urlWindow=window.open(A,"AirportCodes","width=450,height=350");urlWindow.focus}function monthChange(A){if((A.name=="pudate_mo")&&(document.CarSearch.dodate_mo.selectedIndex<A.selectedIndex)){document.CarSearch.dodate_mo.selectedIndex=A.selectedIndex}}function dayChange(A){selected=A.selectedIndex;if((A.name=="pudate_dy")&&(document.CarSearch.dodate_dy.selectedIndex<selected+1)&&(document.CarSearch.dodate_mo.selectedIndex<=document.CarSearch.pudate_mo.selectedIndex)){if(selected<A.length-1){document.CarSearch.dodate_dy.selectedIndex=selected+1}else{document.CarSearch.dodate_mo.selectedIndex+=1;document.CarSearch.dodate_dy.selectedIndex=0}}}function validate(A){re=/S+/;if(!re.test(A.pucity.value)){alert("Please enter a pick-up city");return false}return true}function check_area(){var A=document.CarSearch.puwhere.selectedIndex;if(document.CarSearch.puwhere.options[A].value=="CITY"){document.CarSearch.area.selectedIndex=1}else{if(document.CarSearch.puwhere.options[A].value=="AIRPORT"){document.CarSearch.area.selectedIndex=-1}}return true}function update_docity(){if(document.CarSearch.docity.value){document.CarSearch.same.checked=false}return true}function clear_docity(){document.CarSearch.docity.value="";return true}function check_dropoff(){if(document.CarSearch.same.checked==true){clear_docity()}return true}function submit_to(){update_docity();var A=document.CarSearch.pucity.value;var G=document.CarSearch.docity.value;var C=/[ \t\n\r\f\v]/g;var J=A.replace(C,"");var E=G.replace(C,"");var H=new String(J);var F=new String(E);if(H.length!=3){alert("Invalid or missing pick up airport code");return false}if(F.length>1){if(F.length!=3){alert("Invalid or missing drop off airport code");return false}}var D=document.CarSearch.puwhere.selectedIndex;var B=document.CarSearch.vendor.selectedIndex;if(document.CarSearch.puwhere.options[D].value=="CITY"){var I=new String(document.CarSearch.vendor.options[B].value);if(I.length==0){alert("Please select a Rental Company preference for city searches.");return false}}var D=document.CarSearch.puwhere.selectedIndex;if(document.CarSearch.puwhere.options[D].value=="CITY"){document.CarSearch.action="/nexres/cars/locations.cgi"}else{if(document.CarSearch.puwhere.options[D].value=="AIRPORT"){document.CarSearch.action="/nexres/cars/results.cgi"}}document.CarSearch.submit()}function reset_form(){document.CarSearch.pucity.value="";document.CarSearch.docity.value="";document.CarSearch.area.selectedIndex=-1;document.CarSearch.vendor.selectedIndex=-1;document.CarSearch.carcode.selectedIndex=-1;document.CarSearch.currency.selectedIndex=-1;return true}function hideReadmore(B){if(navigator.appVersion.indexOf("Mac")!=-1){var A=document.getElementById(B);A.style.overflow="auto";A.style.visibility="visible"}}function showSliderValue(B,A,C){if(C!=null){appendCustomChildDiv(A,C[B])}else{appendCustomChildDiv(A,B)}}function toggleSubHeader(A,B){var C=document.getElementById(A);if(!C){return true}if(C.style.display=="none"){document.getElementById(B).src="/html/css/images/minimize.gif";C.style.display="block"}else{document.getElementById(B).src="/html/css/images/restore.gif";C.style.display="none"}return true}function appendCustomChildDiv(A,C){var B=document.getElementById(A);B.innerHTML=C}function toggleMeWithLayoutStatusUpdate(C,B,A){var E=document.getElementById(C);if(!E){return true}var D=document.getElementsByName("wheelsPortletLayoutState");var G="";if(E.style.display=="none"){document.getElementById(B).src="/html/css/images/minimize.gif";E.style.display="block";G="-"}else{document.getElementById(B).src="/html/css/images/restore.gif";E.style.display="none";G="+"}if(D){var F=D[A].value;D[A].value=G+F.substring(1)}return true}function initializeSlider(D,C,F,K,I,G,J,H,E,B,A){if(typeof (C)!="undefined"){if(D=="vertical"){C=new Slider(document.getElementById(F),document.getElementById(K),"vertical")}else{C=new Slider(document.getElementById(F),document.getElementById(K))}C.setMinimum(I);C.setMaximum(G);C.onchange=function(){showSliderValue(getValueFromSlider(I,C.getValue(),A),E,A);document.getElementById(B).value=getValueFromSlider(I,C.getValue(),A)};C._blockIncrement=H;C.setValue(getValueForSlider(I,J,A));showSliderValue(getValueFromSlider(I,C.getValue(),A),E,A);if(F=="howMilesPerDaySlider"){howMilesPerDaySliderElement=C;window.setTimeout("howMilesPerDaySliderElement.recalculate()",500)}else{if(F=="whoOverAllBudgetSlider"){whoOverAllBudgetSliderElement=C;window.setTimeout("whoOverAllBudgetSliderElement.recalculate()",500)}else{if(F=="whoActivityLevelSlider"){whoActivityLevelSliderElement=C;window.setTimeout("whoActivityLevelSliderElement.recalculate()",500)}else{if(F=="whoIndoorOutdoorSlider"){whoIndoorOutdoorSliderElement=C;window.setTimeout("whoIndoorOutdoorSliderElement.recalculate()",500)}else{if(F=="whoFlavourSlider"){whoFlavourSliderElement=C;window.setTimeout("whoFlavourSliderElement.recalculate()",500)}else{if(F=="whatSearchRadiusSlider"){whatSearchRadiusSliderElement=C;window.setTimeout("whatSearchRadiusSliderElement.recalculate()",500)}}}}}}}}var mapSliderElement=null;function initializeMapSlider(D,A,E,K,H,F,I,G){var C=-1*H;var J=-1*F;var B=-1*I;if(typeof (A)!="undefined"){if(D=="vertical"){A=new Slider(document.getElementById(E),document.getElementById(K),"vertical")}else{A=new Slider(document.getElementById(E),document.getElementById(K))}A.setMinimum(J);A.setMaximum(C);A.onchange=function(){zoomTo(A.getAbsValue())};A.setValue(B);A._blockIncrement=G;mapSliderElement=A;window.setTimeout("mapSliderElement.recalculate()",500)}}function getValueForSlider(D,A,C){if(C==null){return A}var B=C.length-D;var F=90;var G=F/B;var E=(A-D)*G+G/2;E=Math.round(E);return E}function getValueFromSlider(C,F,B){if(B==null){return F}var A=B.length-C;var E=90;var G=E/A;var D=F/G+C;D=Math.floor(D);if(D>=A){if(B[0]==""){D=A}else{D=A-1}}return D}var timer;function showIt(){var A=14;if(typeof (window.innerWidth)=="number"){my_width=window.innerWidth;my_height=window.innerHeight}else{if(document.documentElement&&(document.documentElement.clientWidth||document.documentElement.clientHeight)){my_width=document.documentElement.clientWidth;my_height=document.documentElement.clientHeight}else{if(document.body&&(document.body.clientWidth||document.body.clientHeight)){my_width=document.body.clientWidth;my_height=document.body.clientHeight}}}document.getElementById("scrollmenu").style.height=document.body.scrollHeight;document.getElementById("scrollmenu").style.width=document.body.scrollWidth;document.getElementById("fram").style.height=document.body.scrollHeight;document.getElementById("fram").style.width=document.body.scrollWidth-A;document.getElementById("scrollmenu").style.display="block"}function scrolltop(){document.getElementById("scrollmenu").style.top=document.body.scrollTop;timer=setTimeout("scrolltop()",1000)}function hideIt(){document.getElementById("scrollmenu").style.display="none"}function getTabsState(A){var B=A.substring(A.indexOf("?")+1);return B}function getTabsStateQueryString(B,A){var C="";if(B&&B!=""){C=C+getPortletParamStr("tab_state",B)}if(A&&A!=""){C=C+getPortletParamStr("selectedTab",A)}return C}function showMessage(B,A){$(A).style.display="block";$(A).innerHTML=B}function showErrorMessage(B,A){B=LEFT_ERROR_STYLE+B+RIGHT_ERROR_STYLE;showMessage(B,A)}function showConfirmationMessage(B,A){B=LEFT_SUCCESS_STYLE+B+RIGHT_SUCCESS_STYLE;showMessage(B,A)}function hideMessage(A){if($(A)!=null){$(A).style.display="none"}}function setFocus(A,D){try{if(D){if($(D)&&$(D).style.display=="block"){var C=$(A);if(C){C.focus()}}}else{var C=$(A);if(C){C.focus()}}}catch(B){}}function showTripPlanLink(){loadContent("/ext/wheelscpv/tripsuitcaseportlet/view?&tab_state=2_0&selectedTab=TRIP_PLAN&cmd=changeTab",WHEELSCP_TAB_TRIP_PLAN);window.location.href="#tripsuitcase_anchor"}function showTripIdeasLink(){loadContent("/ext/wheelscpv/tripsuitcaseportlet/view?&tab_state=2_1&selectedTab=MY_IDEAS_PAGE&cmd=changeTab",WHEELSCP_TAB_TS_CPV_TRIP_IDEAS);window.location.href="#tripsuitcase_anchor"}function showTripPlanMessagefocus(){window.location.href="#wcp_anchor";showConfirmationMessage(ADDED_TO_TRIP_PLAN+viewTripPlanLink,WCP_MESSAGE_CONTENT_DIV_ID)}function showSliderValue(B,A,C){if(C!=null){appendCustomChildDiv(A,C[B])}else{appendCustomChildDiv(A,B)}}function toggleSubHeader(A,B){var C=document.getElementById(A);if(!C){return true}if(C.style.display=="none"){document.getElementById(B).src="/html/css/images/minimize.gif";C.style.display="block"}else{document.getElementById(B).src="/html/css/images/restore.gif";C.style.display="none"}return true}function appendCustomChildDiv(A,C){var B=document.getElementById(A);B.innerHTML=C}function toggleMeWithLayoutStatusUpdate(C,B,A){var E=document.getElementById(C);if(!E){return true}var D=document.getElementsByName("wheelsPortletLayoutState");var G="";if(E.style.display=="none"){document.getElementById(B).src="/html/css/images/minimize.gif";E.style.display="block";G="-"}else{document.getElementById(B).src="/html/css/images/restore.gif";E.style.display="none";G="+"}if(D){var F=D[A].value;D[A].value=G+F.substring(1)}return true}function initializeSlider(D,C,F,K,I,G,J,H,E,B,A){if(typeof (C)!="undefined"){if(D=="vertical"){C=new Slider(document.getElementById(F),document.getElementById(K),"vertical")}else{C=new Slider(document.getElementById(F),document.getElementById(K))}C.setMinimum(I);C.setMaximum(G);C.onchange=function(){showSliderValue(getValueFromSlider(I,C.getValue(),A),E,A);document.getElementById(B).value=getValueFromSlider(I,C.getValue(),A)};C._blockIncrement=H;C.setValue(getValueForSlider(I,J,A));showSliderValue(getValueFromSlider(I,C.getValue(),A),E,A);if(F=="howMilesPerDaySlider"){howMilesPerDaySliderElement=C;window.setTimeout("howMilesPerDaySliderElement.recalculate()",500)}else{if(F=="whoOverAllBudgetSlider"){whoOverAllBudgetSliderElement=C;window.setTimeout("whoOverAllBudgetSliderElement.recalculate()",500)}else{if(F=="whoActivityLevelSlider"){whoActivityLevelSliderElement=C;window.setTimeout("whoActivityLevelSliderElement.recalculate()",500)}else{if(F=="whoIndoorOutdoorSlider"){whoIndoorOutdoorSliderElement=C;window.setTimeout("whoIndoorOutdoorSliderElement.recalculate()",500)}else{if(F=="whoFlavourSlider"){whoFlavourSliderElement=C;window.setTimeout("whoFlavourSliderElement.recalculate()",500)}else{if(F=="whatSearchRadiusSlider"){whatSearchRadiusSliderElement=C;window.setTimeout("whatSearchRadiusSliderElement.recalculate()",500)}}}}}}}}var mapSliderElement=null;function initializeMapSlider(D,A,E,K,H,F,I,G){var C=-1*H;var J=-1*F;var B=-1*I;if(typeof (A)!="undefined"){if(D=="vertical"){A=new Slider(document.getElementById(E),document.getElementById(K),"vertical")}else{A=new Slider(document.getElementById(E),document.getElementById(K))}A.setMinimum(J);A.setMaximum(C);A.onchange=function(){zoomTo(A.getAbsValue())};A.setValue(B);A._blockIncrement=G;mapSliderElement=A;window.setTimeout("mapSliderElement.recalculate()",500)}}function getValueForSlider(D,A,C){if(C==null){return A}var B=C.length-D;var F=90;var G=F/B;var E=(A-D)*G+G/2;E=Math.round(E);return E}function getValueFromSlider(C,F,B){if(B==null){return F}var A=B.length-C;var E=90;var G=E/A;var D=F/G+C;D=Math.floor(D);if(D>=A){if(B[0]==""){D=A}else{D=A-1}}return D}var timer;function showIt(){var A=14;if(typeof (window.innerWidth)=="number"){my_width=window.innerWidth;my_height=window.innerHeight}else{if(document.documentElement&&(document.documentElement.clientWidth||document.documentElement.clientHeight)){my_width=document.documentElement.clientWidth;my_height=document.documentElement.clientHeight}else{if(document.body&&(document.body.clientWidth||document.body.clientHeight)){my_width=document.body.clientWidth;my_height=document.body.clientHeight}}}document.getElementById("scrollmenu").style.height=document.body.scrollHeight;document.getElementById("scrollmenu").style.width=document.body.scrollWidth;document.getElementById("fram").style.height=document.body.scrollHeight;document.getElementById("fram").style.width=document.body.scrollWidth-A;document.getElementById("scrollmenu").style.display="block"}function scrolltop(){document.getElementById("scrollmenu").style.top=document.body.scrollTop;timer=setTimeout("scrolltop()",1000)}function hideIt(){document.getElementById("scrollmenu").style.display="none"}function getTabsState(A){var B=A.substring(A.indexOf("?")+1);return B}function getTabsStateQueryString(B,A){var C="";if(B&&B!=""){C=C+getPortletParamStr("tab_state",B)}if(A&&A!=""){C=C+getPortletParamStr("selectedTab",A)}return C}function showMessage(B,A){$(A).style.display="block";$(A).innerHTML=B}function showErrorMessage(B,A){B=LEFT_ERROR_STYLE+B+RIGHT_ERROR_STYLE;showMessage(B,A)}function showConfirmationMessage(B,A){B=LEFT_SUCCESS_STYLE+B+RIGHT_SUCCESS_STYLE;showMessage(B,A)}function hideMessage(A){if($(A)!=null){$(A).style.display="none"}}function showTripPlanLink(){loadContent("/ext/wheelscpv/tripsuitcaseportlet/view?&tab_state=2_0&selectedTab=TRIP_PLAN&cmd=changeTab",WHEELSCP_TAB_TRIP_PLAN);window.location.href="#tripsuitcase_anchor"}function showTripIdeasLink(){loadContent("/ext/wheelscpv/tripsuitcaseportlet/view?&tab_state=2_1&selectedTab=MY_IDEAS_PAGE&cmd=changeTab",WHEELSCP_TAB_TS_CPV_TRIP_IDEAS);window.location.href="#tripsuitcase_anchor"}function showTripPlanMessagefocus(){window.location.href="#wcp_anchor";showConfirmationMessage(ADDED_TO_TRIP_PLAN+viewTripPlanLink,WCP_MESSAGE_CONTENT_DIV_ID)}function JSFX_FloatTopLeft(){var B=10,A=10;var D=(navigator.appName.indexOf("Netscape")!=-1);var E=document;var C=document.layers?"":"px";function F(H){var G=E.getElementById?E.getElementById(H):E.all?E.all[H]:E.layers[H];if(E.layers){G.style=G}G.sP=function(I,J){this.style.left=I+C;this.style.top=J+C};G.x=B;G.y=A;return G}window.stayTopLeft=function(){var H=D?pageYOffset:document.documentElement&&document.documentElement.scrollTop?document.documentElement.scrollTop:document.body.scrollTop;var G=(H>A)?H:A;ftlObj.y=G;ftlObj.sP(ftlObj.x,ftlObj.y);setTimeout("stayTopLeft()",0)};ftlObj=F("dummyMovinDiv");stayTopLeft()}function showPoiPopUp(divId,divWidth,divHeight){showIt();var documentWidth=756;var documentHeight=document.body.clientHeight;var left1=0;var top1=75;if(!divWidth){divWidth=0}else{if(documentWidth>divWidth){left1=eval(documentWidth/2)-eval(divWidth/2)}}if(!divHeight){divHeight=75}else{if(documentHeight>divHeight){top1=eval(documentHeight/2)-eval(divHeight/2)}}var popUpDivId=document.getElementById(divId);if(window.top==this){var c=document.getElementById("dummyMovinDiv")}else{if(window.top.document.getElementById("dummyMovinDivSuperUser")){var c=window.top.document.getElementById("dummyMovinDivSuperUser");top1=0}}var top=c.style.top;var topLen=eval(top.length)-2;var topPos=top.substr(0,topLen);popUpDivId.style.top=eval(topPos)+eval(top1);var lft=c.style.left;var lftLen=eval(lft.length)-2;var lftPos=lft.substr(0,lftLen);popUpDivId.style.left=eval(lftPos)+eval(left1);popUpDivId.style.display="block"}function showModalPopUp(B,A,C){showPoiPopUp(B,A,C)}function startOtherBooking(){var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/otherBooking");var B=getPortletParamStr("cmd","search");A=A.replace("EXTRA_PARAMETERS",B);getDivObjById("tsBookingPopId").innerHTML="<div id='tsBookingPopId_loadingAnimation' style='display:none;position:absolute;background-color:#FFFFFF;z-index:9999'><img src='/html/css/images/loading_animation.gif'/></div>";showPoiPopUp("tripSuitcase_popUp",626);AjaxUtil.update(A,otherBookingPopup);overlayOnScrollBar("tripSuitcase_popUp")}function startAirBooking(A){var B=HOTEL_BOOKING_URL;B=B.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/airBooking");var C=getPortletParamStr("cmd","search");C+=getPortletParamStr("airportCode",A);B=B.replace("EXTRA_PARAMETERS",C);getDivObjById("tsBookingPopId").innerHTML="<div id='tsBookingPopId_loadingAnimation' style='display:none;position:absolute;background-color:#FFFFFF;z-index:9999'><img src='/html/css/images/loading_animation.gif'/></div>";showPoiPopUp("tripSuitcase_popUp",626);AjaxUtil.update(B,airBookingPopup);overlayOnScrollBar("tripSuitcase_popUp")}function startCarBooking(){var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/carBooking");var B=getPortletParamStr("cmd","search");A=A.replace("EXTRA_PARAMETERS",B);getDivObjById("tsBookingPopId").innerHTML="<div id='tsBookingPopId_loadingAnimation' style='display:none;position:absolute;background-color:#FFFFFF;z-index:9999'><img src='/html/css/images/loading_animation.gif'/></div>";showPoiPopUp("tripSuitcase_popUp",626);AjaxUtil.update(A,carBookingPopup);overlayOnScrollBar("tripSuitcase_popUp")}function startHotelBooking(B){var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");var C="";if(B!=null){C=C+getPortletParamStr("hotelId",B)}C=C+getPortletParamStr("cmd","search");A=A.replace("EXTRA_PARAMETERS",C);getDivObjById("tsBookingPopId").innerHTML="<div id='tsBookingPopId_loadingAnimation' style='display:none;position:absolute;background-color:#FFFFFF;z-index:9999'><img src='/html/css/images/loading_animation.gif'/></div>";window.location.href="#wcp_anchor";setTimeout("showPoiPopUp('tripSuitcase_popUp',626,380)",1000);AjaxUtil.update(A,hotelDetailsPopup);overlayOnScrollBar("tripSuitcase_popUp")}function changeHotelSearch(B){var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");var C=getPortletParamStr("cmd","search");if(B!=null){C=C+getPortletParamStr("hotelId",B)}A=A.replace("EXTRA_PARAMETERS",C);AjaxUtil.update(A,hotelDetailsPopup)}function searchHotel(){var B="";B=HotelBookingValidator.validateHotelSearch();if(B!=""){B=ERROR_INSTRUCTION+NEW_LINE+B;removeWheelsSiteError();showErrorMessage(B,"bookingErrorDiv");return false}removeErrors("bookingErrorDiv");document.getElementById("bookingProcessDisplay").style.display="block";var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");document.hotelSearch.action=A;var A=document.hotelSearch.action+"&"+Form.serialize(document.hotelSearch);var C=getPortletParamStr("cmd","view");C=C+getPortletParamStr("startingMatchNumber","1");A=A.replace("EXTRA_PARAMETERS",C);AjaxUtil.update(A,hotelDetailsPopup)}function sortHotels(D){var B=document.hotelSearchResults;B.sortBy.value=D;B.startingMatchNumber.value="1";var C="";var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");B.action=A;A=B.action+"&"+Form.serialize(B);C=getPortletParamStr("cmd","view");A=A.replace("EXTRA_PARAMETERS",C);AjaxUtil.update(A,hotelDetailsPopup)}function nextHotels(B){var C=document.hotelSearchResults;C.startingMatchNumber.value=B+15;var D="";var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");C.action=A;A=C.action+"&"+Form.serialize(C);D=getPortletParamStr("cmd","view");A=A.replace("EXTRA_PARAMETERS",D);AjaxUtil.update(A,hotelDetailsPopup)}function previousHotels(B){var C=document.hotelSearchResults;C.startingMatchNumber.value=B-15;var D="";var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");C.action=A;A=C.action+"&"+Form.serialize(C);D=getPortletParamStr("cmd","view");A=A.replace("EXTRA_PARAMETERS",D);AjaxUtil.update(A,hotelDetailsPopup)}function selectHotel(B){var C=document.hotelSearchResults;C.hotelId.value=B;var D="";var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");C.action=A;A=C.action+"&"+Form.serialize(C);D=getPortletParamStr("cmd","select");A=A.replace("EXTRA_PARAMETERS",D);AjaxUtil.update(A,hotelDetailsPopup)}function moreRates(B){var C=document.hotelSearchResults;C.hotelId.value=B;var D="";var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");C.action=A;A=C.action+"&"+Form.serialize(C);D=getPortletParamStr("cmd","moreRates");A=A.replace("EXTRA_PARAMETERS",D);AjaxUtil.update(A,hotelDetailsPopup)}function moreHotels(C,E){var B=document.hotelSearchResults;B.hotelId.value="";B.startingMatchNumber.value="1";B.locationSearchId.value=C;B.locationSearchType.value=E;var D="";var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");B.action=A;A=B.action+"&"+Form.serialize(B);D=getPortletParamStr("cmd","view");A=A.replace("EXTRA_PARAMETERS",D);AjaxUtil.update(A,hotelDetailsPopup)}function selectRoom(hotelCount){var frm=document.hotelSearchResults;var hotelId=eval("document.hotelSearchResults.hotelId_"+hotelCount).value;var hotelName=eval("document.hotelSearchResults.hotelName_"+hotelCount).value;var hotelAddress=eval("document.hotelSearchResults.hotelAddress_"+hotelCount).value;var invSource=eval("document.hotelSearchResults.invSource_"+hotelCount).value;var ratePlanCode=eval("document.hotelSearchResults.ratePlanCode_"+hotelCount).value;var roomTypeCode=eval("document.hotelSearchResults.roomTypeCode_"+hotelCount).value;frm.hotelId.value=hotelId;frm.hotelName.value=hotelName;frm.hotelAddress.value=hotelAddress;frm.invSource.value=invSource;frm.ratePlanCode.value=ratePlanCode;frm.roomTypeCode.value=roomTypeCode;var extraParameters="";var url=HOTEL_BOOKING_URL;url=url.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");frm.action=url;extraParameters=getPortletParamStr("cmd","book");url=frm.action+"&"+Form.serialize(frm);url=url.replace("EXTRA_PARAMETERS",extraParameters);getDivObjById("tsBookingPopId2").innerHTML="<div id='tsBookingPopId2_loadingAnimation' style='display:none;position:absolute;background-color:#FFFFFF;z-index:9999'><img src='/html/css/images/loading_animation.gif'/></div>";AjaxUtil.update(url,bookingPopup);showDivById("tripSuitcase_popUp2");overlayOnScrollBar("tripSuitcase_popUp2")}function updateSpecialOfferCode(){var B="";var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");document.bookHotel.action=A;B=getPortletParamStr("cmd","book");A=document.bookHotel.action+"&"+Form.serialize(document.bookHotel);A=A.replace("EXTRA_PARAMETERS",B);AjaxUtil.update(A,bookingPopup)}var secureWindow;var wentToHttps=false;function continueReservation(){var D="";var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");document.bookHotel.action=A;if(document.bookHotel.specialOfferToken.value==""){document.bookHotel.specialOfferCode.value=""}D=getPortletParamStr("cmd","payment");A=document.bookHotel.action+"&"+Form.serialize(document.bookHotel);A=A.replace("EXTRA_PARAMETERS",D);var B=A.split("/");var C=window.location.href;C=C.substr(0,(C.indexOf("/",(C.indexOf("http://"))+7)));A=A.replace(C,secureURL);A+="&secure=true";wentToHttps=true;closeBookingPopup2();secureWindow=window.open(A,"Booking","height=640px,width=640px,status=yes,scrollbars=yes,toolbar=no,menubar=no,location=no,resizable=yes");if(!secureWindow){popupblockerWarning();return false}}function confirmReservation(){var B="";B=HotelBookingValidator.validatePaymentDetails();if(B!=""){B=ERROR_INSTRUCTION+NEW_LINE+B;removeWheelsSiteError();showErrorMessage(B,"bookingPaymentErrorDiv");return false}removeErrors("bookingPaymentErrorDiv");var C="";var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");document.bookHotel.action=A;A=document.bookHotel.action+"&"+Form.serialize(document.bookHotel);C=getPortletParamStr("cmd","confirm");A=A.replace("EXTRA_PARAMETERS",C);updateInterstitialText("i_t_b",JS_MSG_WCPV_INTERSTITIAL_TEXT_BOOKING);showDivById("requestProcessingId");AjaxUtil.update(A,bookingPopup)}function updateInterstitialText(C,A){var B=$(C);if(B){B.innerHTML=A}}function cancelReservation(){var B="";var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");document.hotelConfirmation.action=A;A=document.hotelConfirmation.action+"&"+Form.serialize(document.hotelConfirmation);B=getPortletParamStr("cmd","cancel");A=A.replace("EXTRA_PARAMETERS",B);if($("tripSuitcase_popUp2").style.display=="block"){AjaxUtil.update(A,bookingPopup)}else{AjaxUtil.update(A,hotelDetailsPopup)}}function hotelOverview(C,B,D){if(!B){B=""}var A=HOTEL_BOOKING_URL;A=A.replace("WHEELS_STRUTS_ACTION","/ext/wheelscpv/tripsuitcaseportlet/hotelBooking");var E="";if(C!=null){E=E+getPortletParamStr("hotelId",C)}if(D=="features"){D="overview"}E=E+getPortletParamStr("cmd",D);A=A.replace("EXTRA_PARAMETERS",E);getDivObjById("tsBookingPopId2").innerHTML="<div id='tsBookingPopId2_loadingAnimation' style='display:none;position:absolute;background-color:#FFFFFF;z-index:9999'><img src='/html/css/images/loading_animation.gif'/></div>";AjaxUtil.update(A,bookingPopup);showDivById("tripSuitcase_popUp2");overlayOnScrollBar("tripSuitcase_popUp2")}var bkmenuItems=new Array("bktab1","bktab2");var bkdivItems=new Array("bktabDiv1","bktabDiv2");function bkchangeImg(A){for(i=0;i<bkmenuItems.length;i++){if(A==bkmenuItems[i]){document.getElementById(bkmenuItems[i]).className="bkTabsSelected";document.getElementById(bkdivItems[i]).style.display="block"}else{document.getElementById(bkmenuItems[i]).className="bktabsNotSelected";document.getElementById(bkdivItems[i]).style.display="none"}}}var bkImageNumber=0;function changeHotelImage(D,C){var B=bkImageNumber+D;bkImageNumber=B;if(B<0||B>C){alert("no more images");return false}for(var A=0;A<C;A++){if(A==B){document.getElementById("bkImageDiv_"+A).style.display="block"}else{document.getElementById("bkImageDiv_"+A).style.display="none"}}if(B==0){document.getElementById("bkImagePrevDiv").style.display="none";document.getElementById("bkImageNextDiv").style.display="block"}else{if(B==C-1){document.getElementById("bkImagePrevDiv").style.display="block";document.getElementById("bkImageNextDiv").style.display="none"}else{document.getElementById("bkImagePrevDiv").style.display="block";document.getElementById("bkImageNextDiv").style.display="block"}}}function openReviewsUrl(B){var A=window.open(B);if(!A){popupblockerWarning();return false}}var HotelBookingValidator={error:null,validateHotelSearch:function(){this.error="";this.error+=CommonValidator.checkBlank("hotelCity",JS_MSG_BOOKING_ENGINE_CITY);this.error+=CommonValidator.checkSpecialCharacters("hotelCity",JS_MSG_BOOKING_ENGINE_CITY);this.error+=CommonValidator.checkBlank("bookingCheckInDate",JS_MSG_BOOKING_ENGINE_CHECK_IN_DATE);this.error+=CommonValidator.checkDateValidityAndFormatMMDDYYYY("bookingCheckInDate",JS_MSG_BOOKING_ENGINE_CHECK_IN_DATE);this.error+=CommonValidator.checkBlank("bookingCheckOutDate",JS_MSG_BOOKING_ENGINE_CHECK_OUT_DATE);this.error+=CommonValidator.checkDateValidityAndFormatMMDDYYYY("bookingCheckOutDate",JS_MSG_BOOKING_ENGINE_CHECK_OUT_DATE);if(this.error==""){var B=new Date();var A=new Date(document.hotelSearch.checkInDate.value);var D=new Date(document.hotelSearch.checkOutDate.value);var C=B.getMonth()+1;var E=new Date(C+"/"+B.getDate()+"/"+B.getFullYear());if(E>A){this.error+=JS_MSG_BOOKING_ENGINE_CHECK_IN_SHOULD_GREATER_THAN_CHECK_OUT_DATE}if(D<=A){this.error+=JS_MSG_BOOKING_ENGINE_CHECK_OUT_DATE_SHOULD_BE_AFTER_CHECK_IN}}return this.error},validatePaymentDetails:function(){this.error="";this.error+=CommonValidator.checkBlank("guestFirstName",JS_MSG_BOOKING_ENGINE_FIRST_NAME);this.error+=CommonValidator.checkBlank("guestLastName",JS_MSG_BOOKING_ENGINE_LAST_NAME);this.error+=CommonValidator.checkBlank("guestPhone",JS_MSG_BOOKING_ENGINE_PHONE);this.error+=CommonValidator.checkBlank("guestEmail",JS_MSG_BOOKING_ENGINE_E_MAIL);this.error+=CommonValidator.checkEmails("guestEmail",JS_MSG_BOOKING_ENGINE_E_MAIL);this.error+=CommonValidator.checkBlank("guestConfirmEmail",JS_MSG_BOOKING_ENGINE_RE_TYPE_E_MAIL);this.error+=CommonValidator.checkEmails("guestConfirmEmail",JS_MSG_BOOKING_ENGINE_RE_TYPE_E_MAIL);this.error+=CommonValidator.checkBlank("cardBrand",JS_MSG_BOOKING_ENGINE_CARD_TYPE);this.error+=CommonValidator.checkBlank("cardNumber",JS_MSG_BOOKING_ENGINE_CARD_NUMBER);this.error+=CommonValidator.checkPositiveInteger("cardNumber",JS_MSG_BOOKING_ENGINE_CARD_NUMBER);this.error+=CommonValidator.checkBlank("cardExpirationMonth",JS_MSG_BOOKING_ENGINE_EXPIRATION_DATE_MM_YY);this.error+=CommonValidator.checkPositiveInteger("cardExpirationMonth",JS_MSG_BOOKING_ENGINE_EXPIRATION_DATE_MM_YY);this.error+=CommonValidator.checkBlank("cardExpirationYear",JS_MSG_BOOKING_ENGINE_EXPIRATION_DATE_MM_YY);this.error+=CommonValidator.checkPositiveInteger("cardExpirationYear",JS_MSG_BOOKING_ENGINE_EXPIRATION_DATE_MM_YY);this.error+=CommonValidator.checkBlank("cardId",JS_MSG_BOOKING_ENGINE_CARD_IDENTIFICATION_NUMBER);this.error+=CommonValidator.checkPositiveInteger("cardId",JS_MSG_BOOKING_ENGINE_CARD_IDENTIFICATION_NUMBER);this.error+=CommonValidator.checkBlank("cardHolderFirstName",JS_MSG_BOOKING_ENGINE_FIRST_NAME);this.error+=CommonValidator.checkBlank("cardHolderLastName",JS_MSG_BOOKING_ENGINE_LAST_NAME);this.error+=CommonValidator.checkBlank("cardHolderStreetAddress1",JS_MSG_BOOKING_ENGINE_STREET_ADDRESS);this.error+=CommonValidator.checkBlank("cardHolderCity",JS_MSG_BOOKING_ENGINE_CITY);this.error+=CommonValidator.checkBlank("cardHolderState",JS_MSG_BOOKING_ENGINE_STATE);this.error+=CommonValidator.checkBlank("cardHolderCountryCode",JS_MSG_BOOKING_ENGINE_COUNTRY);this.error+=CommonValidator.checkBlank("cardHolderPostalCode",JS_MSG_BOOKING_ENGINE_POSTAL_CODE);if(document.bookHotel.email.value!=document.bookHotel.confirmEmail.value){this.error+=JS_MSG_BOOKING_ENGINE_CONFIRM_EMAIL_ERROR_MESSAGE+NEW_LINE}var A=new Date();var C=A.getMonth()+1;var B=A.getYear();if(B<2000){B=B+1900}B=B-2000;if(Number(document.bookHotel.expirationYear.value)<B){this.error+=JS_MSG_BOOKING_ENGINE_EXPIRATION_DATE_ERROR_MESSAGE+NEW_LINE}else{if(Number(document.bookHotel.expirationMonth.value)<C&&Number(document.bookHotel.expirationYear.value)==B){this.error+=JS_MSG_BOOKING_ENGINE_EXPIRATION_DATE_ERROR_MESSAGE+NEW_LINE}}return this.error}};function copyAddress(){var A=document.bookHotel;if(A.addressChooser.checked){A.firstName.value=A.guestFirstName.value;A.lastName.value=A.guestLastName.value}}var regtxt=new RegExp(/[^a-zA-Z,\s]+/);function uncheckAllCategories(){document.ticketsForm.ACTTYPE_all.checked=false}function uncheckCategories(){document.ticketsForm.ACTTYPE_attraction.checked=false;document.ticketsForm.ACTTYPE_shows.checked=false;document.ticketsForm.ACTTYPE_tours.checked=false;document.ticketsForm.ACTTYPE_outdoor.checked=false;document.ticketsForm.ACTTYPE_dining.checked=false;document.ticketsForm.ACTTYPE_transport.checked=false}function copyDate2(p_date,f2){var ddate=new Date(p_date);var dm=ddate.getMonth()+1;if(dm<10){dm="0"+dm}var dd=ddate.getDate();if(dd<10){dd="0"+dd}eval("document.ticketsForm."+f2+"_mm").value=dm;eval("document.ticketsForm."+f2+"_dd").value=dd}function ticketsValidate(){var C=document.ticketsForm.citytext.value;if(regtxt.test(C)||C==""){showErrorMessage(JS_MSG_BOOKING_ENGINE_PLEASE_INSERT_ONLY_TEXT,"otherBookingErrorDiv");return false}var B=document.ticketsForm.ticketsFromDate.value;var F=document.ticketsForm.ticketsToDate.value;if(B==""){showErrorMessage(JS_MSG_BOOKING_ENGINE_ENTER_START_DATE,"otherBookingErrorDiv");return false}else{if(F==""){showErrorMessage(JS_MSG_BOOKING_ENGINE_ENTER_START_DATE,"otherBookingErrorDiv");return false}}if(B!=""){var A=new Date();var D=A.getMonth()+1;var E=new Date(D+"/"+A.getDate()+"/"+A.getFullYear());var G=new Date(B);if(E>G){showErrorMessage(JS_MSG_BOOKING_ENGINE_START_DATE_SHOULD_BE_GREATER_OR_EQUAL_TODAYS_DATE,"otherBookingErrorDiv");return false}else{copyDate2(B,"from")}}if(F!=""){var A=new Date();var D=A.getMonth()+1;var E=new Date(D+"/"+A.getDate()+"/"+A.getFullYear());var G=new Date(F);if(E>G){showErrorMessage(JS_MSG_BOOKING_ENGINE_END_DATE_SHOULD_BE_GREATER_OR_EQUAL_TO_TODAYS_DATE,"otherBookingErrorDiv");return false}else{copyDate2(F,"to")}}if(F!=""&&B!=""){var F=new Date(F);var B=new Date(B);if(F<B){showErrorMessage(JS_MSG_BOOKING_ENGINE_END_DATE_GREATER_THAN_START_DATE,"otherBookingErrorDiv");return false}}setTimeout("closeBookingPopup()",1000);return true}function copyDate(p_date,f2,formName){var ddate=new Date(p_date);var dm=ddate.getMonth()+1;if(dm<10){dm="0"+dm}var dd=ddate.getDate();if(dd<10){dd="0"+dd}eval("document."+formName+"."+f2+"_mo").value=dm;eval("document."+formName+"."+f2+"_dy").value=dd}function copyDate1(p_date,f2,formName){var ddate=new Date(p_date);var dm=ddate.getMonth()+1;if(dm<10){dm="0"+dm}var dd=ddate.getDate();if(dd<10){dd="0"+dd}eval("document."+formName+"."+f2+"Month").value=dm;eval("document."+formName+"."+f2+"Day").value=dd}function flightvalid(){var H=document.AirSearchForm.leavingFrom.value;var E=document.AirSearchForm.goingTo.value;if(regtxt.test(H)||regtxt.test(E)||H==""||E==""){showErrorMessage(JS_MSG_BOOKING_ENGINE_TEXT_IN_FORM,"airBookingErrorDiv");return false}var I=document.AirSearchForm.ddate.value;var G=document.AirSearchForm.rdate.value;var F=parseInt(document.AirSearchForm.adults.value);var C=parseInt(document.AirSearchForm.children.value);var A=parseInt(document.AirSearchForm.seniors.value);var J=F+C+A;if(I==""){showErrorMessage(JS_MSG_BOOKING_ENGINE_ENTER_DEPARTURE_AND_RETURN_DATE,"airBookingErrorDiv");return false}else{if(G==""){showErrorMessage(JS_MSG_BOOKING_ENGINE_ENTER_DEPARTURE_AND_RETURN_DATE,"airBookingErrorDiv");return false}}if(I!=""){var B=new Date();var D=B.getMonth()+1;var L=new Date(D+"/"+B.getDate()+"/"+B.getFullYear());var K=new Date(I);if(L>K){showErrorMessage(JS_MSG_BOOKING_ENGINE_DEPATURE_DATE_GREATER_THAN_TODAYS_DATE,"airBookingErrorDiv");return false}else{copyDate1(I,"dateLeaving","AirSearchForm")}}if(G!=""){var B=new Date();var D=B.getMonth()+1;var L=new Date(D+"/"+B.getDate()+"/"+B.getFullYear());var K=new Date(G);if(L>K){showErrorMessage(JS_MSG_BOOKING_ENGINE_RETURN_DATE_GREATER_THAN_TODAYS_DATE,"airBookingErrorDiv");return false}else{copyDate1(G,"dateReturning","AirSearchForm")}}if(G!=""&&I!=""){var G=new Date(G);var I=new Date(I);if(G<I){showErrorMessage(JS_MSG_BOOKING_ENGINE_RETURN_DATE_GREATER_THAN_DEPARTURE_DATE,"airBookingErrorDiv");return false}}if(J>6){showErrorMessage(JS_MSG_BOOKING_ENGINE_MAXIMUM_SIX,"airBookingErrorDiv");return false}setTimeout("closeBookingPopup()",3000);return true}function fnFlightType(B){if(B=="oneway"){strURL=AIR_BOOKING_URL+"&flightType="+B+"&dateTypeSelect="+document.getElementById("radioplusMinusDates").value+"&leavingFrom="+document.getElementById("leavingFrom").value+"&goingTo="+document.getElementById("goingTo").value+"&leavingDate="+document.getElementById("f_date_c5").value+"&dateLeavingTime="+document.getElementById("datelt").value+"&adults="+document.getElementById("FO_adults").value+"&children="+document.getElementById("FO_children").value+"&seniors="+document.getElementById("FO_seniors").value+"&minorsAge0="+document.getElementById("FO_child1").value+"&minorsAge1="+document.getElementById("FO_child2").value+"&minorsAge2="+document.getElementById("FO_child3").value+"&minorsAge3="+document.getElementById("FO_child4").value+"&minorsAge4="+document.getElementById("FO_child5").value}else{if(B=="multicity"){strURL=AIR_BOOKING_URL+"&flightType="+B+"&dateTypeSelect="+document.getElementById("radioplusMinusDates").value+"&leavingFrom1="+document.getElementById("leavingFrom").value+"&goingTo1="+document.getElementById("goingTo").value+"&adults="+document.getElementById("FO_adults").value+"&children="+document.getElementById("FO_children").value+"&seniors="+document.getElementById("FO_seniors").value+"&minorsAge0="+document.getElementById("FO_child1").value+"&minorsAge1="+document.getElementById("FO_child2").value+"&minorsAge2="+document.getElementById("FO_child3").value+"&minorsAge3="+document.getElementById("FO_child4").value+"&minorsAge4="+document.getElementById("FO_child5").value}}var A=window.open(strURL);if(!A){popupblockerWarning();return false}}function carvalid(){var E=document.CarSearch.pucity.value;var D=document.CarSearch.docity.value;if(regtxt.test(E)||regtxt.test(D)){showErrorMessage(JS_MSG_BOOKING_ENGINE_ONLY_TEXT_IN_PICK_UP_FIELD,"carBookingErrorDiv");return false}var B=document.CarSearch.pudate.value;var H=document.CarSearch.dodate.value;if(E==""){showErrorMessage(JS_MSG_BOOKING_ENGINE_PICK_UP_CITY,"carBookingErrorDiv");return false}if(B==""){showErrorMessage(JS_MSG_BOOKING_ENGINE_PICKUP_AND_DROPOFF_DATE,"carBookingErrorDiv");return false}else{if(H==""){showErrorMessage(JS_MSG_BOOKING_ENGINE_PICKUP_AND_DROPOFF_DATE,"carBookingErrorDiv");return false}}if(B!=""){var A=new Date();var C=A.getMonth()+1;var F=new Date(C+"/"+A.getDate()+"/"+A.getFullYear());var G=new Date(B);if(F>G){showErrorMessage(JS_MSG_BOOKING_ENGINE_PICKUP_DATE_SHOULD_BE_GREATER_OR_EQUAL_TO_TODAYS_DATE,"carBookingErrorDiv");return false}else{copyDate(B,"pudate","CarSearch")}}if(H!=""){var A=new Date();var C=A.getMonth()+1;var F=new Date(C+"/"+A.getDate()+"/"+A.getFullYear());var G=new Date(H);if(F>G){showErrorMessage(JS_MSG_BOOKING_ENGINE_DROPOFF_DATE_SHOULD_BE_GREATER_OR_EQUAL_TO_TODAYS_DATE,"carBookingErrorDiv");return false}else{copyDate(H,"dodate","CarSearch")}}if(H!=""&&B!=""){var H=new Date(H);var B=new Date(B);if(H<B){showErrorMessage(JS_MSG_BOOKING_ENGINE_DROPOFF_DATE_SHOULD_BE_GREATER_PICK_UP_DATE,"carBookingErrorDiv");return false}}setTimeout("closeBookingPopup()",1000);return true}function resetHotelSearch(){document.hotelSearch.reset()}function killPopUpAlert(A){WheelsAlerts.killAlert(A);A=null}function closeBookingPopup(){if(getDivObjById("tripSuitcase_PoiPopUp").style.display!="block"){hideIt()}if(wentToHttps){addBookedHotel("addBookedHotel");wentToHttps=false}closeBookingPopup2();hideDivById("tripSuitcase_popUp");getDivObjById("tsBookingPopId").innerHTML="<p>&nbsp;</p>"}function closeBookingPopup2(){hideDivById("tripSuitcase_popUp2")}function overlayOnScrollBar(B){if(navigator.appVersion.indexOf("Mac")!=-1){var A=document.getElementById(B);A.style.overflow="auto";A.style.visibility="visible"}}function testInsecure(){var A=normalURL+"/html/wheelscpv/portlet/booking/hotelConfirmation.jsp";if($("tripSuitcase_popUp").style.display=="block"){showDivById("tripSuitcase_popUp2");showDivById("tsBookingPopId2");getDivObjById("tsBookingPopId2").innerHTML="<div id='tsBookingPopId2_loadingAnimation' style='display:none;position:absolute;background-color:#FFFFFF;z-index:9999'><img src='/html/css/images/loading_animation.gif'/></div>";AjaxUtil.update(A,bookingPopup)}else{showDivById("tripSuitcase_popUp");showDivById("tsBookingPopId");getDivObjById("tsBookingPopId").innerHTML="<div id='tsBookingPopId2_loadingAnimation' style='display:none;position:absolute;background-color:#FFFFFF;z-index:9999'><img src='/html/css/images/loading_animation.gif'/></div>";AjaxUtil.update(A,hotelDetailsPopup)}window.focus();window.setTimeout("closeSecureWindow();","1000")}function closeSecureWindow(){secureWindow.close();secureWindow=null}function showTripSuitcase(B){var A="p_p_id_wcpv_tripsuitcase_portlet_";if(B){showTripSuitcaseFlag=true;if($(A)){$(A).style.display="block"}}else{showTripSuitcaseFlag=false;if($(A)){$(A).style.display="none"}}}function showWheelsCoalesced(A){var B="wcp_main";if(A){if($(B)){$(B).style.display="block"}}else{if($(B)){$(B).style.display="none"}if($("wcp_message_content")){$("wcp_message_content").style.display="none"}if($("overview_content")){$("overview_content").style.display="none"}if($("where_content")){$("where_content").style.display="none"}if($("what_content")){$("what_content").style.display="none"}if($("when_content")){$("when_content").style.display="none"}if($("who_content")){$("who_content").style.display="none"}if($("how_content")){$("how_content").style.display="none"}if($("portlet_results_content")){$("portlet_results_content").style.display="none"}}}function getPrePlannedTrip(A){var B=document.tripSuitcaseForm.geoCodeStr.value;$("_prePannedTripId").value=A;if(B.length>0){showModalPopUp("prePlannedTripConfirmDivId",300,60)}else{prePlannedTripConfirmYes()}}function prePlannedTripConfirmYes(){var A=$("_prePannedTripId").value;closePlannedTripConfirmDiv();window.location.href="/rtw?tripId="+A}function closePlannedTripConfirmDiv(){$("prePlannedTripConfirmDivId").style.display="none";hideIt()}