// JavaScript Document


function Carica (Url) {
	
	google.load("jquery", "1.2.6");  
	google.load("jqueryui", "1.5.2");  
	var yourLocation = google.loader.ClientLocation.address.city
	var strUrl;
	
	strUrl = Url;
	strUrl += "&iploc=" + yourLocation;
	
	objHTTP = getXMLHttp();
	objHTTP.open("GET", strUrl, true);
	objHTTP.onreadystatechange = function() {elaboraRisposta(objHTTP)}
	objHTTP.send(null)
	
	
}


function elaboraRisposta(pobjHTTP) {
	if (pobjHTTP.readyState == 4) {
		//var strResponse = pobjHTTP.responseText;
		//location.href = "http://www.appalti.org/common/logindenied.aspx?cod="+Codipfax;
		//alert(pobjHTTP.responseText);
	
   }
}



function getXMLHttp() {
	var xmlhttp = null;
	if (window.ActiveXObject) {
	  if (navigator.userAgent.toLowerCase().indexOf("msie 5") != -1) {
	  xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
	  } else {
		xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
	  }
	}
	if (!xmlhttp && typeof(XMLHttpRequest) != 'undefined') {
	  xmlhttp = new XMLHttpRequest()
	}
	return xmlhttp
}


