<!--

function httpRequest() {
	var xmlhttp = null;
/*	browserUtente = navigator.userAgent.toUpperCase();
	if (typeof(XMLHttpRequest) === "function" || typeof(XMLHttpRequest) === "object")
		xmlhttp = new XMLHttpRequest();
	else if (window.ActiveXObject && browserUtente.indexOf("MSIE 4") < 0) {
		if (browserUtente.indexOf("MSIE 5") < 0)
			xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
		else
			xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
 	}
	else
		alert("Your browser does not support AJAX!");
*/

	if (window.XMLHttpRequest)
		xmlhttp = new XMLHttpRequest(); // Firefox, Safari, Opera
	else if (window.ActiveXObject)
		xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); // IE 6+
	else if (window.ActiveXObject)
		xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); // IE 5
	else
		alert("Your browser does not support AJAX!");
/*	try {
		xmlhttp = new XMLHttpRequest();
  	} catch(e) {
    	try {
			xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
		} catch(e) {
			xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
   		
	}
	}
*/
	return xmlhttp;
}

function getQueryByEntita(id_entita, path) {
	
	xmlhttp1 = httpRequest();
	xmlhttp1.onreadystatechange = function() {
		if (xmlhttp1.readyState == 4) {
  			document.getElementById('prova').innerHTML = xmlhttp1.responseText;
  		}
	}
    xmlhttp1.open("GET", path + "system/application/models/entita_model2.php?id_entita=" + id_entita, true);
	xmlhttp1.send(null);

}

// function setStatus(schema.table, table.field, value, where)
// onChange=\"setStatus('path''sistema.entita_sottoservizi', 'entita_sottoservizi.stato_redazione', ".$next_status.", 'entita_sottoservizi.id_entita = ".$entita_id."')\" 

function setStatussasdasd(table, field, value, where) {
	

	xmlhttp2 = httpRequest();
	xmlhttp2.onreadystatechange = function() {
		/*if (xmlhttp2.readyState == 4) {
  			document.getElementById('prova').innerHTML = xmlhttp2.responseText;
  		}*/
	}
    xmlhttp2.open("GET", path_file);
	xmlhttp2.send(null);

}

function hideDiv(div_id) {
	//document.getElementById(div_id).style.visibility = "visible";
}


//-->
