function Validator(theForm)
{

  if (theForm.title.value == "")
  {
    alert("La preghiamo di compilare interamente il formulario."); // no title
    theForm.title.focus();
    return (false);
  }

  if (theForm.fname.value == "")
  {
    alert("La preghiamo di compilare interamente il formulario."); // no vorname
    theForm.fname.focus();
    return (false);
  }

if (theForm.lname.value == "")
  {
    alert("La preghiamo di compilare interamente il formulario."); // no name
    theForm.lname.focus();
    return (false);
  }
  
if (theForm.street.value == "")
  {
    alert("La preghiamo di compilare interamente il formulario."); // no strasse
    theForm.street.focus();
    return (false);
  }  

if (theForm.postcode.value == "")
  {
    alert("La preghiamo di compilare interamente il formulario."); // no plz
    theForm.postcode.focus();
    return (false);
  }

if (theForm.city.value == "")
  {
    alert("La preghiamo di compilare interamente il formulario."); // no plz
    theForm.city.focus();
    return (false);
  }

if (theForm.country.value == "")
  {
    alert("La preghiamo di compilare interamente il formulario."); // no land
    theForm.country.focus();
    return (false);
  }

if (theForm.phone.value == "")
  {
    alert("La preghiamo di compilare interamente il formulario."); // no telefon
    theForm.phone.focus();
    return (false);
  }

  if (theForm.email.value == "")
  {
    alert("La preghiamo di compilare interamente il formulario."); // no email
    theForm.email.focus();
    return (false);
  }
  
 if (theForm.email.value != "" && (theForm.email.value.indexOf("@") == -1 || theForm.email.value.indexOf(".") == -1)) {
	alert("La preghiamo di compilare interamente il formulario.");     // email is not correct
	theForm.email.focus();
    return (false);	
}

return (true);
}

