var xmlHttp;

function showUser(str,ap,t)
{ 

	 if(str!=""){
	 	document.getElementById("lives").style["visibility"]="visible";
	 }else{
		document.getElementById("lives").style["visibility"]="hidden";
	 }
	 
	 
xmlHttp=GetXmlHttpObject3();
if (xmlHttp==null)
 {
 alert ("Browser does not support HTTP Request")
 return
 }
var url="getuser.php?q="+str+"&ap="+ap+"&t="+t;
xmlHttp.onreadystatechange=stateChanged3 ;
xmlHttp.open("GET",url,true);
xmlHttp.send(null);
}

function stateChanged3() 
{ 
if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
 { 
 	var s=xmlHttp.responseText;
	
	document.getElementById("lives").innerHTML=s;
	/*
	var o=window.frames[0]
	o.document.open();
	o.document.write (s);
	o.document.close();
	*/  
  } 
}

function GetXmlHttpObject3()
{

var xmlHttp=null;


try
 {
 // Firefox, Opera 8.0+, Safari
 xmlHttp=new XMLHttpRequest();
 }
catch (e)
 {
	 // Internet Explorer
	 try
	  {
	  xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");	
	  }
	 catch (e)
	  {
		   try
		  {
		  xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");	
		  }
		 catch (e)
		  {
		  alert("error");
		  }
	  }
 }

 
return xmlHttp;
} 
