<!--
function check(){
	if(document.contatti.oggetto.value==""){
	alert("Selezionare una voce");
	return false;
	}	
	if(document.contatti.nominativo.value==""){
		alert("Il campo 'Nominativo' e' obbligatorio");
		return false;
	}
	if(document.contatti.azienda.value==""){
		alert("Il campo 'Azienda' e' obbligatorio");
		return false;
	}
	if(document.contatti.indirizzo.value==""){
		alert("Il campo 'Indirizzo' e' obbligatorio");
		return false;
	}
	if(document.contatti.citta.value==""){
		alert("Il campo 'Citta\'' e' obbligatorio");
		return false;
	}
	/*
	if(document.contatti.tel.value==""){
		alert("Inserire il numero di telefono");
		return false;
	}
	*/
	tel=document.contatti.tel.value; 
	if(isNaN(tel)){
		alert("Inserire correttamente il numero di telefono: senza spazi, lettere o caratteri speciali");
		return false;
	}
	if(document.contatti.mail.value==""){
		alert("Inserire un indirizzo email");
		return false;
	}
	if(document.contatti.mail.value.indexOf("@")==-1 || document.contatti.mail.value.indexOf(".")==-1){
		alert("Inserire correttamente l'indirizzo email");
		return false;
	}
	if(document.contatti.mex.value==""){
		alert("Inserire il messaggio!");
		return false;
	}
	if(!document.contatti.dati.checked){
		alert("Obbligatorio acconsentire al trattamento dei dati personali");
		return false;
	}
	document.contatti.submit();
}

function check_en(){
	if(document.contatti.oggetto.value==""){
	alert("Select an option");
	return false;
	}	
	if(document.contatti.nominativo.value==""){
		alert("'Name' field is mandatory");
		return false;
	}
	if(document.contatti.azienda.value==""){
		alert("'Company' field is mandatory");
		return false;
	}
	if(document.contatti.indirizzo.value==""){
		alert("'Address' field is mandatory");
		return false;
	}
	if(document.contatti.citta.value==""){
		alert("'City' field is mandatory");
		return false;
	}
	/*
	if(document.contatti.tel.value==""){
		alert("Inserire il numero di telefono");
		return false;
	}
	*/
	tel=document.contatti.tel.value; 
	if(isNaN(tel)){
		alert("Enter a valid phone number: without spaces, letters or special characters.");
		return false;
	}
	if(document.contatti.mail.value==""){
		alert("Enter an email address");
		return false;
	}
	if(document.contatti.mail.value.indexOf("@")==-1 || document.contatti.mail.value.indexOf(".")==-1){
		alert("Enter a valid email address");
		return false;
	}
	if(document.contatti.mex.value==""){
		alert("Enter a message!");
		return false;
	}
	if(!document.contatti.dati.checked){
		alert("Authorize the treatment of personal data.");
		return false;
	}
	document.contatti.submit();
}


function checkReg(){
	if(document.contatti.nome.value==""){
		alert("Il campo 'Nome' e' obbligatorio");
		return false;
	}
	if(document.contatti.cognome.value==""){
		alert("Il campo 'Cognome' e' obbligatorio");
		return false;
	}
	if(document.contatti.indirizzo.value==""){
		alert("Il campo 'Indirizzo' e' obbligatorio");
		return false;
	}
	if(document.contatti.citta.value==""){
		alert("Il campo 'Citta\'' e' obbligatorio");
		return false;
	}
	if(document.contatti.mail.value==""){
		alert("Inserire un indirizzo email");
		return false;
	}
	if(document.contatti.mail.value.indexOf("@")==-1 || document.contatti.mail.value.indexOf(".")==-1){
		alert("Inserire correttamente l'indirizzo email");
		return false;
	}
	if(document.contatti.pwd.value==""){
		alert("Inserire una password");
		return false;
	}
	if(document.contatti.pwd2.value==""){
		alert("Inserire la conferma della password");
		return false;
	}
	if(!(document.contatti.pwd2.value==document.contatti.pwd.value)){
		alert("Le password devono coincidere");
		return false;
	}
	if(!document.contatti.dati.checked){
		alert("Obbligatorio acconsentire al trattamento dei dati personali");
		return false;
	}
	if(!document.contatti.age.selectedIndex){
	alert("Selezionare una fascia d'eta'");
	return false;
	}
	document.contatti.submit();
}

function checkReg_en(){
	if(document.contatti.nome.value==""){
		alert("'Name' field is mandatory");
		return false;
	}
	if(document.contatti.cognome.value==""){
		alert("'Surname' field is mandatory");
		return false;
	}
	if(document.contatti.indirizzo.value==""){
		alert("'Address' field is mandatory");
		return false;
	}
	if(document.contatti.citta.value==""){
		alert("'City' field is mandatory");
		return false;
	}
	if(document.contatti.mail.value==""){
		alert("Enter a email address");
		return false;
	}
	if(document.contatti.mail.value.indexOf("@")==-1 || document.contatti.mail.value.indexOf(".")==-1){
		alert("Enter a valid email address");
		return false;
	}
	if(document.contatti.pwd.value==""){
		alert("Enter a password");
		return false;
	}
	if(document.contatti.pwd2.value==""){
		alert("Retype your password");
		return false;
	}
	if(!(document.contatti.pwd2.value==document.contatti.pwd.value)){
		alert("Passwords must match");
		return false;
	}
	if(!document.contatti.dati.checked){
		alert("Authorize the treatment of personal data.");
		return false;
	}
	document.contatti.submit();
}



function check_newpw(){
	if(document.pass.pwd.value==""){
		alert("Inserire una password");
		return false;
	}
	if(document.pass.pwd2.value==""){
		alert("Inserire la conferma della password");
		return false;
	}
	if(!(document.pass.pwd2.value==document.pass.pwd.value)){
		alert("Le password devono coincidere");
		return false;
	}
	document.pass.submit();
}

function check_newpw_en(){
	if(document.pass.pwd.value==""){
		alert("Enter the new password");
		return false;
	}
	if(document.pass.pwd2.value==""){
		alert("Re-enter the new password");
		return false;
	}
	if(!(document.pass.pwd2.value==document.pass.pwd.value)){
		alert("Passwords must match");
		return false;
	}
	document.pass.submit();
}

function check_lostpw(){
	if(document.lostpw.nome.value==""){
		alert("Il campo 'Nome' e' obbligatorio");
		return false;
	}
	if(document.lostpw.cognome.value==""){
		alert("Il campo 'Cognome' e' obbligatorio");
		return false;
	}
	if(document.lostpw.mail.value==""){
		alert("Inserire un indirizzo email");
		return false;
	}
	if(document.lostpw.mail.value.indexOf("@")==-1 || document.lostpw.mail.value.indexOf(".")==-1){
		alert("Inserire correttamente l'indirizzo email");
		return false;
	}
	document.lostpw.submit();
}

function check_lostpw_en(){
	if(document.lostpw.nome.value==""){
		alert("'Name' field is mandatory");
		return false;
	}
	if(document.lostpw.cognome.value==""){
		alert("'Surname' field is mandatory");
		return false;
	}
	if(document.lostpw.mail.value==""){
		alert("Please enter an email address");
		return false;
	}
	if(document.lostpw.mail.value.indexOf("@")==-1 || document.lostpw.mail.value.indexOf(".")==-1){
		alert("Please enter a _valid_ email address.");
		return false;
	}
	document.lostpw.submit();
}

function check_en(){
	if(document.contatti.oggetto.value==""){
	alert("Select an option");
	return false;
	}		
	if(document.contatti.nominativo.value==""){
		alert("'Name' field is mandatory");
		return false;
	}
	if(document.contatti.azienda.value==""){
		alert("'Company' field is mandatory");
		return false;
	}
	if(document.contatti.indirizzo.value==""){
		alert("'Address' field is mandatory");
		return false;
	}
	if(document.contatti.citta.value==""){
		alert("'City' field is mandatory");
		return false;
	}
	tel=document.contatti.tel.value; 
	if(isNaN(tel)){
		alert("Please insert a vaild telephone number: without spaces, letters or special characters");
		return false;
	}
	if(document.contatti.mail.value==""){
		alert("Please enter an email address");
		return false;
	}
	if(document.contatti.mail.value.indexOf("@")==-1 || document.contatti.mail.value.indexOf(".")==-1){
		alert("Please enter a valid email address");
		return false;
	}
	if(document.contatti.mex.value==""){
		alert("Please enter the message!");
		return false;
	}
	if(!document.contatti.dati.checked){
		alert("You must consent to the treatment of your personal data");
		return false;
	}
	document.contatti.submit();
}

function checkCont()
	{
	if(document.contenuto.sezione.value == "")
		{
		alert("Il campo \"Sezione\" e' obbligatorio");
		return false;	
		}
		
	if(document.contenuto.titolo.value == "")
		{
		alert("Il campo \"Titolo\" e' obbligatorio");
		return false;
		}
	if(document.contenuto.articolo.value == "")
		{
		alert("Il campo \"Articolo\" e' obbligatorio");
		return false;
		}
	document.contenuto.submit();
	}
	
function checkCont_en()
	{
	if(document.contenuto.sezione.value == "")
		{
		alert("'Section' field is mandatory");
		return false;	
		}
		
	if(document.contenuto.titolo.value == "")
		{
		alert("'Title' field is mandatory");
		return false;
		}
	if(document.contenuto.articolo.value == "")
		{
		alert("'Message' field is mandatory");
		return false;
		}
	document.contenuto.submit();
	}


function check_newsletter(){
	if(document.newsletter.nome.value==""){
		alert("Il campo 'Nome' e' obbligatorio");
		return false;
	}
	if(document.newsletter.cognome.value==""){
		alert("Il campo 'Cognome' e' obbligatorio");
		return false;
	}
	if(document.newsletter.mail.value==""){
		alert("Inserire un indirizzo email");
		return false;
	}
	if(document.newsletter.mail.value.indexOf("@")==-1 || document.newsletter.mail.value.indexOf(".")==-1){
		alert("Inserire correttamente l'indirizzo email");
		return false;
	}
	if(document.newsletter.citta.value==""){
		alert("Il campo 'Citta\'' e' obbligatorio");
		return false;
	}	
	if(!document.newsletter.age.selectedIndex){
		alert("Selezionare una fascia d'eta'");
		return false;
	}
	if(!document.newsletter.dati.checked){
		alert("Obbligatorio acconsentire al trattamento dei dati personali");
		return false;
	}
	document.newsletter.submit();
}
//-->