function IndexClass()
{
}
IndexClass.prototype.$ = function(str){return document.getElementById(str);}
IndexClass.prototype.$$ = function(str){return document.getElementsByName(str);}
IndexClass.prototype.SelectHotelOrFlight = function(tp,count)
{
	for(var i=1;i<=count;i++)
	{
		var li = this.$("index_search"+i);
		var li2 = this.$("search"+i);
		if(i==tp)
		{
			li.style.display="block";
			this.SelectAnySearchStyle(li2,i,true);
		}else{
			li.style.display="none";
			this.SelectAnySearchStyle(li2,i,false);
		}
	}
}
IndexClass.prototype.SelectAnySearchStyle=function(li,tp,state)
{
	if(state)
	{
		switch(tp)
		{
			case 1:
			li.className="index_top_main_left_top_flight_select";
			break;
			case 2:
			li.className="index_top_main_left_top_hotel_select";
			break;
		}
	}else{
		switch(tp)
		{
			case 1:
			li.className="index_top_main_left_top_flight_noselect";
			break;
			case 2:
			li.className="index_top_main_left_top_hotel_noselect";
			break;
		}

	}
}
IndexClass.prototype.SelectTravelType=function(tp)
{
	var returnDate = this.$("returnDate");
	var retrundatestrleter = this.$("retrundatestrleter");
	if(tp==1)
	{
		returnDate.disabled="disabled";
		returnDate.value="";
		returnDate.className="flight_search_boxcontrol_box_disabled";
		retrundatestrleter.className="flight_search_boxcontrol_str_info_disabled";
	}else{
		returnDate.disabled="";
		returnDate.className="flight_search_boxcontrol_box";
		retrundatestrleter.className="flight_search_boxcontrol_str_info";
	}
}
var IClass = new IndexClass();