// JavaScript Document

function controllo_preventivi(){
	
with(document.preventivi) {
	
	
	
	if(nome.value=="") {
	alert("Error, fill the field NAME");
	nome.focus();
	return false;
	}
	if(cognome.value=="") {
	alert("Error, fill the field SURNAME");
	cognome.focus();
	return false;
	}
	if(telefono.value=="") {
	alert("Error, fill the field PHONE");
	telefono.focus();
	return false;
	}
	if(email.value=="") {
	alert("Error, fill the field E-MAIL");
	email.focus();
	return false;
	}
	if(msg.value=="") {
	alert("Insert a message please");
	email.focus();
	return false;
	}
	if(privacy.value!="on") {
	alert("Please check the box PRIVACY");
	privacy.focus();
	return false;
	}
	
	}
	//alert("Controllo effettuato con successo. Il modulo sar&agrave; inviato.");
	return true;
}


