var xmlHttp;
function getXmlHttpObject(){
	var objXMLHttp=null;
	if(window.XMLHttpRequest){
 		objXMLHttp=new XMLHttpRequest();
 	}else if(window.ActiveXObject){
 		objXMLHttp=new ActiveXObject("Microsoft.XMLHTTP");
 	}
 	return objXMLHttp;
}
function showTestimonials(id,page_id){
	xmlHttp=getXmlHttpObject();
	if(xmlHttp==null){
		alert("You are using a too old browser. Please update the browser.");
		return;
	}else{
		var url="../scripts/list_testimonials.php";
		url=url+"?page_id="+page_id;
		xmlHttp.onreadystatechange=loadTestimoials;
		xmlHttp.open("GET",url,true);
		xmlHttp.send(null);
		for(x=1;x<=2;x++){
			if(x==id){
				document.getElementById(x).className='sub_navi_sel';
			}else{
				document.getElementById(x).className='sub_navi';
			}
		}
	}
}
function loadTestimoials(){
	if(xmlHttp.readyState!=4){
		document.getElementById("body").innerHTML='Loading Testimonials...';	
	}
	if(xmlHttp.readyState==4){		
	document.getElementById("body").innerHTML=xmlHttp.responseText;		
	}
}
