<!-- 
function verifica(form) {

	if (form.tbNome.value == "") {     
		alert("Occorre riempire il campo NOME E COGNOME.");
		form.tbNome.focus();
		return false;
	}
	if (form.tbEMail.value == "") {     
		alert("Occorre riempire il campo EMAIL.");
		form.tbEMail.focus();
		return false;
	} 			
	if(!isEmail(form.tbEMail.value)) {     
		alert("L'indirizzo di e-mail non è valido.");
		form.tbEMail.focus();
		return false; 
	}
	/*if (form.tbSocieta.value == "") {     
		alert("Occorre riempire il campo SOCIETA/ENTE.");
		form.tbSocieta.focus();
		return false;
	}*/	
	if (form.tbContattoTel.value!="") {
		if(!form.tbContattoTel.value.match(/^\d+$/) || form.tbContattoTel.value.length<8 || form.tbContattoTel.value.length>16){
			alert("Inserire un numero di TELEFONO valido! (da 8 a 16 caratteri numerici).");
			form.tbContattoTel.focus();
			return false;
		}
	}	
	if (form.tbRichiesta.value == "") {     
		alert("Occorre riempire il campo RICHIESTA.");
		form.tbRichiesta.focus();
		return false;
	}	
	// ACCETTAZIONE
	if (form.chkPresoVisione.checked == false) {
		alert("Bisogna accettare l'informativa.");
		return false;		
	}	
	
//alert("Il modulo è stato accettato.");   
return true; 
}

/* CONTROLLO EMAIL */
function isEmail(what){
	var i=new RegExp("^.*\\@(\\[?)[a-zA-Z0-9\\-\\.]+\\.([a-zA-Z]{2,3}|[0-9]{1,3})(\\]?)$");
	if(!i.test(what)) 
		return false;
	return true;
}

function isnum(obj) {
	if (isNaN(obj.value) || parseInt(obj.value)<0 || parseInt(obj.value) > 9999)
	{
		alert('Nel campo è possibile immettere solo numeri!');
		obj.value="";
		obj.focus();
		return true;
	}
	else
	{
		return false;
	}
}		
// -->

