// JavaScript Document
function loadXMLDoc(page,obj){//added by trung.le 04/21/2011 to using Ajax
var xmlhttp;
var obj= document.getElementById(obj);
if (window.XMLHttpRequest)
  {// code for IE7+, Firefox, Chrome, Opera, Safari
  xmlhttp=new XMLHttpRequest();
  }
else
  {// code for IE6, IE5
  xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
  }
xmlhttp.onreadystatechange=function()
  {
  if (xmlhttp.readyState==4 && xmlhttp.status==200)
    {
    obj.innerHTML=xmlhttp.responseText;
    }
  }
xmlhttp.open("GET",page,true);
xmlhttp.send();
}

function Show(id){
	tmp=document.getElementById(id);
	if(tmp.style.display=="none")
		tmp.style.display="block";
}
function Hide(id){
	tmp=document.getElementById(id);
	if(tmp.style.display=="block")
		tmp.style.display="none";
}
var current_id="default";
function ShowItem(id){
	var prev_obj = document.getElementById("item_" + current_id);
	var obj = document.getElementById("item_" + id);
	if(prev_obj){
		prev_obj.style.display = "none";
	}
	document.getElementById("tab_" + current_id).className = "tab_unselect";
	if(obj){
		obj.style.display = "block";
		current_id = id;
	}
	document.getElementById("tab_" + id).className = "tab_select";
}
var current="tour";
function ShowTour(id){
	var prev_obj = document.getElementById("item_" + current);
	var obj = document.getElementById("item_" + id);
	if(prev_obj){
		prev_obj.style.display = "none";
	}
	document.getElementById("tab_" + current).className = "tab_unselect";
	if(obj){
		obj.style.display = "block";
		current = id;
	}
	document.getElementById("tab_" + id).className = "tab_select";
}
var current2="cruise";
function ShowCruise(id){
	var prev_obj = document.getElementById("item_" + current2);
	var obj = document.getElementById("item_" + id);
	if(prev_obj){
		prev_obj.style.display = "none";
	}
	document.getElementById("tab_" + current2).className = "tab_unselect";
	if(obj){
		obj.style.display = "block";
		current2 = id;
	}
	document.getElementById("tab_" + id).className = "tab_select";
}
function Show_Compare(url){
	var sParams = "scrollbars=yes,toolbar=no,menubar=no,resizable=yes,location=no,height=800,width=1250,top=20,left=20";
	var wname = "Cruise_Compare";
	var dest = (url=='')?"cruise-compare.php":url;
	window.open(dest,wname,sParams);
}
function TourPrint(url){
	var sParams = "scrollbars=yes,toolbar=no,menubar=no,resizable=yes,location=no,height=750,width=890,top=20,left=20";
	var wname = "Tour_Print";
	var dest = (url=='')?"tour-print.php":url;
	window.open(dest,wname,sParams);
}

function CruisePrint(url){
	var sParams = "scrollbars=yes,toolbar=no,menubar=no,resizable=yes,location=no,height=750,width=890,top=20,left=20";
	var wname = "Cruise_Print";
	var dest = (url=='')?"cruise-print.php":url;
	window.open(dest,wname,sParams);
}
function ShowEmail(url){
	var sParams = "scrollbars=yes,toolbar=no,menubar=no,resizable=yes,location=no,height=550,width=700,top=20,left=20";
	var wname = "Send_Email";
	var dest = (url=='')?"send-email.php":url;
	window.open(dest,wname,sParams);
}
function ShowHide(id){
	showmn = document.getElementById(id);
	if(showmn.style.display=="none"){
		showmn.style.display="block";
	}
	else if(showmn.style.display=="block"){
		showmn.style.display="none";
	}
}
function Show_Campare(id, name){
	var sParams = "scrollbars=yes,toolbar=no,menubar=no,resizable=yes,location=no,height=800,width=1350,top=20,left=20";
	var wname = "ShowSlide_print";
	var dest = "cruise-compare.php";
	window.open(dest,wname,sParams);

}
function Show_Charter(url){
	var sParams = "scrollbars=yes,toolbar=no,menubar=no,resizable=yes,location=no,height=800,width=1250,top=20,left=20";
	var wname = "Show_Charter";
	var dest = (url=='')?"cruise-charter.php":url;
	window.open(dest,wname,sParams);

}
function ShowHideClude(id, id1, id2){
	showmn = document.getElementById(id);
	showmn1 = document.getElementById(id1);
	showmn2 = document.getElementById(id2);
	if(showmn.style.display=="none"){
		showmn.style.display="block";
		showmn1.style.display="none";
		showmn2.style.display="block";
	}
	else if(showmn.style.display=="block"){
		showmn.style.display="none";
		showmn1.style.display="block";
		showmn2.style.display="none";
	}
}
function ShowPrice(id, id1, id2){
	showmn = document.getElementById(id);
	showmn1 = document.getElementById(id1);
	showmn2 = document.getElementById(id2);
	if(showmn.style.display=="block"){
		showmn.style.display="none";
		showmn1.style.display="none";
		showmn2.style.display="block";
	}
}
function ShowTCruise(id, id1, id2){
	showmn = document.getElementById(id);
	showmn1 = document.getElementById(id1);
	showmn2 = document.getElementById(id2);
	if(showmn.style.display=="none"){
		showmn.style.display="block";
		showmn1.style.display="block";
		showmn2.style.display="none";
	}
	else if(showmn.style.display=="block"){
		showmn.style.display="none";
		showmn1.style.display="none";
		showmn2.style.display="block";
	}
}
