function IsEmailValid(checkThisEmail) {
	var myEMailIsValid = true;
	var myAtSymbolAt = checkThisEmail.indexOf('@');
	var myLastDotAt = checkThisEmail.lastIndexOf('.');
	var mySpaceAt = checkThisEmail.indexOf(' ');
	var myLength = checkThisEmail.length;
	
	if (myAtSymbolAt < 1 )
	 {myEMailIsValid = false}
	
	if (myLastDotAt < myAtSymbolAt)
	 {myEMailIsValid = false}
	
	if (myLength - myLastDotAt <= 2)
	 {myEMailIsValid = false}
	
	if (mySpaceAt != -1)
	{myEMailIsValid = false}
	
	if(myEMailIsValid==true)
	 IsEmailValid==true
	else
	 IsEmailValid==false
	
	return myEMailIsValid
}

function donl() {
	if ((document.getElementById("nome").value == "")) {
		alert("Devi inserire il tuo nome");
		document.getElementById("nome").focus();
		return false;
	}
	if ((document.getElementById("email").value == "")) {
		alert("Devi inserire la tua email");
		document.getElementById("email").focus();
		return false;
	}
	if ((IsEmailValid(document.getElementById("email").value)==false)) {
		alert("Attenzione, formato email non valido");
		document.getElementById("email").focus();
		return false;
	}
	document.getElementById("nl").submit();
}


function resp(v,s) {
	if(s=="undefined") { s="" }; 
	if(v=="ms07") {
	  
	  ms7 = "&#105;&#110;&#102;&#111;";
	  ms7 = ms7 + String.fromCharCode(8*8);
	  ms7 = ms7 + "mediashape";
	  ms7 = ms7 + "&#46;&#105;&#116;";
	  if(s!="") { MSLink=ms7+"?subject="+s; ms7=s+String.fromCharCode(8*8)+"mediashape.it"; } else { MSLink=ms7; };
	  document.write("<a href=&#109;&#97;&#105;&#108;&#116;&#111;:"+MSLink+">")
	  document.write(""+ms7+"</a>")
	}


}
