var req; function synchCombo(idMaster,idSlave,nomeMappa,url) { var master = document.getElementById(idMaster); var index = master.selectedIndex; if (typeof XMLHttpRequest != "undefined") { req = new XMLHttpRequest(); } else if (window.ActiveXObject) { req = new ActiveXObject("Microsoft.XMLHTTP"); } var masterValue = master.options[index].value; var postDataStr = "idMaster=" + encodeURIComponent(idMaster) + "&idSlave=" + encodeURIComponent(idSlave) + "&masterValue=" + encodeURIComponent(masterValue) + "&nomeMappa=" + encodeURIComponent(nomeMappa); req.open("POST", url, true); req.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); req.onreadystatechange = synchComboCallback; req.send(postDataStr); } function synchSearch(idMaster,idSlave,url) { var master = document.getElementById(idMaster); if (typeof XMLHttpRequest != "undefined") { req = new XMLHttpRequest(); } else if (window.ActiveXObject) { req = new ActiveXObject("Microsoft.XMLHTTP"); } var searchString = master.value; var postDataStr = "idMaster=" + encodeURIComponent(idMaster) + "&idSlave=" + encodeURIComponent(idSlave) + "&searchString=" + encodeURIComponent(searchString); req.open("POST", url, true); req.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); req.onreadystatechange = synchComboCallback; req.send(postDataStr); } function synchComboCallback() { if (req.readyState == 4) { if (req.status == 200) { var xmlDoc = req.responseXML.documentElement; var idSlave = xmlDoc.getElementsByTagName("idSlave")[0]; var slave = document.getElementById(idSlave.childNodes[0].nodeValue); slave.options.length = 0; var xRows = xmlDoc.getElementsByTagName("entry"); for(i=0;i"+name+""); }