	window.dhx_globalImgPath="./js/calendar/codebase/imgs/";
	window.onload=function(){enableTooltips("tooltip")};
	var day = new Date();

	var today;
	var oneDay;
	var twoDays;
	var twoYears;
	
	today = new Date(day);
	today = (today.getMonth()+1)+"/"+today.getDate()+"/"+today.getFullYear();
	today = new Date(today);
	
	oneDay = new Date(day);
	oneDay.setDate(oneDay.getDate()+1);
	oneDay = (oneDay.getMonth()+1)+"/"+oneDay.getDate()+"/"+oneDay.getFullYear();
	oneDay = new Date(oneDay);
	
	twoDays = new Date(day);
	twoDays.setDate(twoDays.getDate()+2);
	twoDays = (twoDays.getMonth()+1)+"/"+twoDays.getDate()+"/"+twoDays.getFullYear();
	twoDays = new Date(twoDays);
	
	twoYears = new Date(day);
	twoYears = (twoYears.getMonth()+1)+"/"+twoYears.getDate()+"/"+(twoYears.getFullYear()+2);
	twoYears = new Date(twoYears);
	
	var mCal, mCal2;
	window.onload=function(){
		mCal=new dhtmlxCalendarObject('calInput1', true, {isWinHeader: true,isWinDrag: false,headerButtons: "X",headerText: "Arrival Date"});
		mCal.setSkin("simplecolorsand");
		
		mCal.setSensitive(today, twoYears);
		mCal.setDateFormat("%m/%d/%Y");
		mCal.setDate(today);
		mCal2=new dhtmlxCalendarObject('calInput2', true, {isWinHeader: true,isWinDrag: false,headerButtons: "X",headerText: "Departure Date"});
		mCal2.setSkin("simplecolorsand");
		mCal2.setSensitive(oneDay, twoYears);
		mCal2.setDateFormat("%m/%d/%Y");
		mCal2.setDate(twoDays);
		mCal.attachEvent("onClick",mSelectDate);
		mCal2.attachEvent("onClick", mSelectDate2);
	}
	function mSelectDate(date) {
			beginMonth = mCal.getFormatedDate("%m", date);
			beginDay = mCal.getFormatedDate("%d", date);
			beginYear = mCal.getFormatedDate("%Y", date);
			if(new Date(mCal2.getDate()) <= new Date(mCal.getDate())){
				var d = new Date(mCal.getFormatedDate("%m/%d/%Y"));
				d.setDate(d.getDate()+2);
				mCal2.setDate((d.getMonth()+1)+"/"+d.getDate()+"/"+d.getFullYear());
			}
	}
	function mSelectDate2(date){
		if(new Date(mCal2.getDate()) <= new Date(mCal.getDate())){
			var d = new Date(mCal.getFormatedDate("%m/%d/%Y"));
			d.setDate(d.getDate()+1);
			mCal2.setDate((d.getMonth()+1)+"/"+d.getDate()+"/"+d.getFullYear());
		}
	}
	
	function hideCal1(){
		mCal.hide();
	}	
	function hideCal2(){
		mCal2.hide();	
	}
	function changeRoomType(roomType){
		switch(roomType.value){
			case "suite":
				if(roomType.checked){
					//set value to suite
					irmResort = document.getElementById("IRMResort");
					irmCountry = document.getElementById("Country");
					
					irmResort.value = "08";
					irmCountry.value = "RDP08"
				}
			break;
			case "standard":
				if(roomType.checked){
					//set value to standard
					irmResort = document.getElementById("IRMResort");
					irmCountry = document.getElementById("Country");
					
					irmResort.value = "03";
					irmCountry.value = "RDP03"
				}
			break;
		}
	}
