	function set_form_date_fields_mmyyyy_Outbound(oMonYrDdl, oDayDdl, date) 
	{
		try 
		{
			if ((oMonYrDdl == undefined) || (oDayDdl == undefined) || (date == undefined)) return;
			if ((oMonYrDdl == "") || (oDayDdl == "") || (date == "")) return;
			var arrDate=date.split("/",3);
			if (arrDate.length <=0) return;
			for(var i=0; i< oDayDdl.length; i++){
				if (arrDate[2]==oDayDdl.options[i].value)  {
					oDayDdl.selectedIndex = i;
				}
			}	
			var sMmYy = "";
			//sMmYy = sMmYy.concat(arrDate[1],arrDate[0]);
			sMmYy = arrDate[1];
			for(var i=0; i< oMonYrDdl.length; i++){
				if (sMmYy==oMonYrDdl.options[i].value)  {
					oMonYrDdl.selectedIndex = i;
				}
			}					
		changeday();
		} 
		catch(e) {
		}
	}
	function set_form_date_fields_mmyyyy_Return(oMonYrDdl, oDayDdl, date) 
	{
		try 
		{
			if ((oMonYrDdl == undefined) || (oDayDdl == undefined) || (date == undefined)) return;
			if ((oMonYrDdl == "") || (oDayDdl == "") || (date == "")) return;
			var arrDate=date.split("/",3);
			if (arrDate.length <=0) return;
			for(var i=0; i< oDayDdl.length; i++){
				if (arrDate[2]==oDayDdl.options[i].value)  {
					oDayDdl.selectedIndex = i;
				}
			}	
			var sMmYy = "";
			//sMmYy = sMmYy.concat(arrDate[1],arrDate[0]);
			sMmYy = arrDate[1];
			for(var i=0; i< oMonYrDdl.length; i++){
				if (sMmYy==oMonYrDdl.options[i].value)  {
					oMonYrDdl.selectedIndex = i;
				}
			}					
		} 
		catch(e) {
		}
	}
	function changeday()
	{
		window.document.forms[0].ctlAvailCriteria_cboRetMon.value = window.document.forms[0].ctlAvailCriteria_cboDepMon.value;
		selYrRetuOnChange();
		window.document.forms[0].ctlAvailCriteria_cboRetDay.value = window.document.forms[0].ctlAvailCriteria_cboDepDay.value;
		setCalendarDates();
	}	
	//we have to set the calendar date when we change the departure date through the list
	function setCalendarDates()
	{
		var mdepmonyear=document.forms[0].ctlAvailCriteria_cboDepMon.value.split(" ");	
		var mretmonyear=window.document.forms[0].ctlAvailCriteria_cboRetMon.value.split(" ");
		document.forms[0].outDate.value=mdepmonyear[1] + '/' + mdepmonyear[0] + '/' + window.document.forms[0].ctlAvailCriteria_cboDepDay.value ;
		document.forms[0].retDate.value=mretmonyear[1] + '/' + mretmonyear[0] + '/' + window.document.forms[0].ctlAvailCriteria_cboRetDay.value ;
	}
	function setReturnCalendarDate()
	{
		var mretmonyear=window.document.forms[0].ctlAvailCriteria_cboRetMon.value.split(" ");
		document.forms[0].retDate.value=mretmonyear[1] + '/' + mretmonyear[0] + '/' + window.document.forms[0].ctlAvailCriteria_cboRetDay.value ;
	}
	function getInfants()
	{
		if (document.forms[0].ctlAvailCriteria_cboInfants){
			var lenInfant = document.forms[0].ctlAvailCriteria_cboInfants.options.length;
			var lenadult = document.forms[0].ctlAvailCriteria_cboAdults.options.length;
			for(var i=0;i<=lenInfant;i++)
			{
				document.forms[0].ctlAvailCriteria_cboInfants.remove(0);
			}
			var strMaxNumberOfInfants = 1 ;
			if (strMaxNumberOfInfants < 0 )
			{
			    var seladult = document.forms[0].ctlAvailCriteria_cboAdults.value;
			   
			}
			else
			{
			   //if (document.forms[0].ctlAvailCriteria_cboAdults.value >= strMaxNumberOfInfants)
			       var seladult = strMaxNumberOfInfants;
			   //else
				   //var seladult = document.forms[0].ctlAvailCriteria_cboAdults.value;
		   }
			   
			for (var j=0;j<=seladult;j++)
			{
			//if ($('ctlAvailCriteria_cboInfants') != null){
				add_Infant = new Option(j,j);
				document.forms[0].ctlAvailCriteria_cboInfants.options[j]=add_Infant;
			//	}
			}
		}
	}