     function Modulo() {

     var cognome = document.modulo.cognome.value;
     var nome = document.modulo.nome.value;
     var telefono = document.modulo.telefono.value;
     var provincia = document.modulo.provincia.options[document.modulo.provincia.selectedIndex].value;
     var email = document.modulo.email.value;
     var privacy = document.modulo.privacy.value;
    
    

     var email_reg_exp = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-]{2,})+\.)+([a-zA-Z0-9]{2,})+$/;


        if ((nome == "") || (nome == "undefined")) {
           alert("Il campo NOME e' obbligatorio.");
           document.modulo.nome.focus();
           return false;
        }
 

        else if ((cognome == "") || (cognome == "undefined")) {
           alert("Il campo COGNOME e' obbligatorio.");
           document.modulo.cognome.focus();
           return false;
        }
        


        else if ((provincia == "") || (provincia == "undefined")) {
           alert("Il campo PROVINCIA e' obbligatorio.");
           document.modulo.provincia.focus();
           return false;
        }

          else if (!email_reg_exp.test(email) || (email == "") || (email == "undefined")) {
           alert("Inserire un INDIRIZZO EMAIL corretto.");
           document.modulo.email.select();
           return false;
        }


        else if ((isNaN(telefono)) || (telefono == "") || (telefono == "undefined")) {
           alert("Inserire il Numero nel campo TELEFONO, Senza SPAZI e/o LETTERE.");
           document.modulo.telefono.value = "";
           document.modulo.telefono.focus();
           return false;
        }
        
   if (!document.modulo.privacy.checked) { alert("ATTENZIONE! devi prestare il consenso al trattamento dati per inviare la scheda.");
 return false; 
 
 }


        else {
           document.modulo.action = "send.php";
           document.modulo.submit();
        }
  }

