
function popup(name,URL,width,height) 
{
    name = window.open(URL,name,'left=0,top=0,width='+width+',height='+height+',resizable=no,titlebar=yes,menubar=no,status=no,scrollbars=no,toolbars=no,location=no');
    name.focus();
    return;
}

function opener_location(URL) {
    window.opener.location = URL;
    return false;
}

function popup2(name,URL,width,height) 
{
    name = window.open(URL,name, 'left=30,top=30,width='+width+',height='+height+',resizable=no,titlebar=yes,menubar=no,status=no,scrollbars=yes,toolbars=no,location=no');
    name.focus();
    return;
}



function inviamodulo()
//invia modulo senza controlli
	{ 
		document.modulo.submit(); 
	} 



function inviamodulo_CONTROLLI()
{
	var cn=document.modulo.Nome.value
	var dob=document.modulo.Societa.value
	var tn=document.modulo.Telefono.value
	
	// controllo presenza Cognome e Nome
	if ((cn == "") || (cn == "undefined")) 
	{ 
		alert("Il campo COGNOME e NOME è obbligatorio."); 
		document.modulo.Nome.focus(); 
		return false; 
	}	

	// controllo presenza Società
	else if ((dob == "") || (dob == "undefined")) 
	{ 
		alert("Il campo SOCIETA' è obbligatorio."); 
		document.modulo.Societa.focus(); 
		return false; 
	}	

	// controllo presenza Telefono
	else if ((tn == "") || (tn == "undefined")) 
	{ 
		alert("Il campo TELEFONO è obbligatorio."); 
		document.modulo.Telefono.focus(); 
		return false; 
	}	
	
	//INVIA IL MODULO 
	else 
	{ 
		document.modulo.submit(); 
	} 

	

}



function vaia(regione)
	{
		
		pagina=regione + ".htm"
		parent.location.href=pagina
		return
	}
