/*
**************************************************************************
Brochures.js
JS Functions used on the brochure request Page

AS 22/08/05

if ((document.NieuwsBriefForm.title.selectedIndex==0) || (document.NieuwsBriefForm.title.value == null)) { 
		alert("Vul uw titel in.");
		return false;
	}
**************************************************************************
*/
  function validateForm() 
  {
	  
	 if ((document.taf.naam.value == "") || (document.taf.naam.value == null)) {
      alert("Vul jouw naam in.");
      document.taf.naam.focus();
      return false;
    
    }   
    
  
    <!--- Ensure a valid looking email address --->
    if ((document.taf.email.value == "") || 
        (document.taf.email.value == null) ||
        (-1 == document.taf.email.value.indexOf("@")) ||
        (-1 == document.taf.email.value.indexOf(".")) ||
        (-1 != document.taf.email.value.indexOf(",")) ||
        (-1 != document.taf.email.value.indexOf("#")) ||
        (-1 != document.taf.email.value.indexOf("!")) ||
        (-1 != document.taf.email.value.indexOf(" ")) ||
        (document.taf.email.value.length < 5)) {
          alert("Vul je e-mail adres in.");
          document.taf.email.focus();
          return false;
    }  
	
	 if ((document.taf.naamvriend.value == "") || (document.taf.naamvriend.value == null)) {
      alert("Vul de naam van je vrien(in) in.");
      document.taf.naamvriend.focus();
      return false;
    
    }   
	
	
	 if ((document.taf.emailvriend.value == "") || 
        (document.taf.emailvriend.value == null) ||
        (-1 == document.taf.emailvriend.value.indexOf("@")) ||
        (-1 == document.taf.emailvriend.value.indexOf(".")) ||
        (-1 != document.taf.emailvriend.value.indexOf(",")) ||
        (-1 != document.taf.emailvriend.value.indexOf("#")) ||
        (-1 != document.taf.emailvriend.value.indexOf("!")) ||
        (-1 != document.taf.emailvriend.value.indexOf(" ")) ||
        (document.taf.emailvriend.value.length < 5)) {
          alert("Vul je het e-mail adres van je vriend(in) in.");
          document.taf.emailvriend.focus();
          return false;
    }  
		
	else
	{
	document.taf.submit();
	}

  }
  
  /*function checkBR1()
  {
    if (document.taf.chk2005.checked == true)
		{document.taf.chk2006.checked = false;}
  }
function checkBR2()
  {
    if (document.taf.chk2006.checked == true)
		{document.taf.chk2005.checked = false;}
  }*/
  
  function validateNieuwsbrief() 
   {
    if ((document.Vbeurs.uname.value == "") || (document.Vbeurs.uname.value == null)) {
      alert("Vul je achternaam in.");
      document.Vbeurs.uname.focus();
      return false;
    }   
	
	if (!document.Vbeurs.ip[0].checked &&
    !document.Vbeurs.ip[1].checked &&
    !document.Vbeurs.ip[2].checked)  
	{
                alert ( "Vul je aanspreektitel in." );
                return false;
        }
			

    <!--- Ensure a valid looking email address --->
    if ((document.Vbeurs.ucomment.value == "") || 
        (document.Vbeurs.ucomment.value == null) ||
        (-1 == document.Vbeurs.ucomment.value.indexOf("@")) ||
        (-1 == document.Vbeurs.ucomment.value.indexOf(".")) ||
        (-1 != document.Vbeurs.ucomment.value.indexOf(",")) ||
        (-1 != document.Vbeurs.ucomment.value.indexOf("#")) ||
        (-1 != document.Vbeurs.ucomment.value.indexOf("!")) ||
        (-1 != document.Vbeurs.ucomment.value.indexOf(" ")) ||
        (document.Vbeurs.ucomment.value.length < 5)) {
          alert("Vul je e-mail adres in.");
          document.Vbeurs.ucomment.focus();
          return false;
    } 
	if (document.Vbeurs.chkNieuwsBrief1.checked == false){
      alert("Wil je aangeven dat je de nieuwsbrief u wilt ontvangen?");
      document.Vbeurs.chkNieuwsBrief.focus();
      return false;
    }  
	else
	{
	document.Vbeurs.submit();
	}
  }
  
 function validateFeedback()
{
if ( document.feedback.uname.value == "" )
        {
                alert ( "Vul je achternaam in." );
                return false;
        }
		else
		{
			if ( document.feedback.ucomment.value == "" )
			{
					alert ( "Vul je e-mail adres in." );
					return false;
			}
		else
			{
			document.feedback.submit();
			}
		}
}		


