var XMLHTTP;

function Richiesta3(V1,V2,V3,V4,V5,V6,V7,V8,V9,V10,V11,V12,V13,V14,V15,V16,V17,V18,V19,V20,V21,V22)
{
   var url = "inserimentodbformprenota.asp?vv1=" + V1 + "&vv2=" + V2 + "&vv3=" + V3 + "&vv4=" + V4 + "&vv5=" + V5 + "&vv6=" + V6 + "&vv7=" + V7 + "&vv8=" + V8 + "&vv9=" + V9 + "&vv10=" + V10 + "&vv11=" + V11 + "&vv12=" + V12 + "&vv13=" + V13 + "&vv14=" + V14 + "&vv15=" + V15 + "&vv16=" + V16 + "&vv17=" + V17 + "&vv18=" + V18 + "&vv19=" + V19 + "&vv20=" + V20 + "&vv21=" + V21 + "&vv22=" + V22 + "";
   XMLHTTP = RicavaBrowser3(CambioStato3);
   XMLHTTP.open("GET", url, true);
   XMLHTTP.send(null);
}


function CambioStato3()
{
    if (XMLHTTP.readyState == 4)
    {
        var R = document.getElementById("risultato3");
        R.innerHTML = XMLHTTP.responseText;
 target = document.getElementById("richiesta_prenotazione");
               target.style.display = "none";
    }
}

function RicavaBrowser3(QualeBrowser)
{
    if (navigator.userAgent.indexOf("MSIE") != (-1))
    {
        var Classe = "Msxml2.XMLHTTP";
        if (navigator.appVersion.indexOf("MSIE 5.5") != (-1));
        {
            Classe = "Microsoft.XMLHTTP";
        } 
        try
        {
            OggettoXMLHTTP = new ActiveXObject(Classe);
            OggettoXMLHTTP.onreadystatechange = QualeBrowser;
            return OggettoXMLHTTP;
        }
        catch(e)
        {
            alert("Errore: l'ActiveX non verrą eseguito!");
        }
    }
    else if (navigator.userAgent.indexOf("Mozilla") != (-1))
    {
        OggettoXMLHTTP = new XMLHttpRequest();
        OggettoXMLHTTP.onload = QualeBrowser;
        OggettoXMLHTTP.onerror = QualeBrowser;
        return OggettoXMLHTTP;
    }
    else
    {
        alert("L'esempio non funziona con altri browser!");
    }
}
