// JavaScript Document
var xmlHttp;
function visitor(){
	
	xmlHttp = GetXmlHttpObject();
		if(xmlHttp == null){
			alert("Browser does not support HTTP Request");
			return;
		}
	var URL = "config/visitcount.php";
	//URL = URL + "?page=insert";
	//URL = URL + "&sid" + Math.random();
		
	xmlHttp.onreadystatechange=stateChanged; 
	xmlHttp.open("GET",URL,true); //Server (3)
	xmlHttp.send(null);
	display();	
	//setTimeout("display()", 10);
}
function display(){
	
	xmlHttp = GetXmlHttpObject();
		if(xmlHttp == null){
			alert("Browser does not support HTTP Request");
			return;
		}
	var URL = "config/visitdisplay.php";
	//URL = URL + "?page=display";
	//URL = URL + "&sid" + Math.random();
		
	xmlHttp.onreadystatechange=stateChanged; 
	xmlHttp.open("GET",URL,true); //Server (3)
	xmlHttp.send(null);
	
	
}
//XmlHttpRequest (2)
function stateChanged(){	
	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
 	{	 
 		document.getElementById("txtHint").innerHTML=xmlHttp.responseText;	
		//displayToday();
 	}
	
}
//////////////////End Visit Count//////////////////////////////////////////////////////////////



//////Browser (1)
function GetXmlHttpObject()
{
var xmlHttp=null;
try
 {
 // Firefox, Opera 8.0+, Safari
 xmlHttp=new XMLHttpRequest();
 }
catch (e)
 {
 // Internet Explorer
 try
  {
  xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
  }
 catch (e)
  {
  xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
  }
 }
return xmlHttp;
}