// JavaScript Document
var strResult;
function updatePage()
{
  if (xmlHttp.readyState == 4)
  	{
    	if (xmlHttp.status == 200)
    		{
    			
				var response = xmlHttp.responseText;
				
				return response;

    		}
  	}
  else
  	{
  		//waiting to load...
  		
  	}
}

function callServer(Url,Content) {

	if (window.XMLHttpRequest)
		{
        	xmlHttp = new XMLHttpRequest();
    	} 
    else if (window.ActiveXObject)
    	{
        	xmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
        }

	if(Content == void 0)
		{
			xmlHttp.open("GET", Url, false);
			xmlHttp.send(null);	
		}
	else
		{
            xmlHttp.open("POST", Url, false);
			xmlHttp.setRequestHeader("Content-Type","application/x-www-form-urlencoded");
			xmlHttp.setRequestHeader("Content-Length",Content.length);
			xmlHttp.send(Content);
		}


  //xmlHttp.onreadystatechange = updatePage;
  //cant not set async = true, because i must need to get the return value....

  
	if (xmlHttp.readyState == 4)
	{
	if (xmlHttp.status == 200)
		{
			
			var response = xmlHttp.responseText;
			
			return response;
	
		}
	}
	else
	{
	//waiting to load...
	
	}

  
}