function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function BTW() {
  var x= 1500;
  var y= 1.21;
  var resultaat= x * y;
  alert(resultaat);
}

var isNN = (navigator.appName.indexOf("Netscape")!=-1);
function autoTab(input,len, e) {
var keyCode = (isNN) ? e.which : e.keyCode; 
var filter = (isNN) ? [0,8,9] : [0,8,9,16,17,18,37,38,39,40,46];
if(input.value.length >= len && !containsElement(filter,keyCode)) {
input.value = input.value.slice(0, len);
input.form[(getIndex(input)+1) % input.form.length].focus();
}
function containsElement(arr, ele) {
var found = false, index = 0;
while(!found && index < arr.length)
if(arr[index] == ele)
found = true;
else
index++;
return found;
}
function getIndex(input) {
var index = -1, i = 0, found = false;
while (i < input.form.length && index == -1)
if (input.form[i] == input)index = i;
else i++;
return index;
}
return true;
}

var checkobj
function agreesubmit(el){
checkobj=el
if (document.all||document.getElementById){
for (i=0;i<checkobj.form.length;i++){  //hunt down submit button
var tempobj=checkobj.form.elements[i]
if(tempobj.type.toLowerCase()=="submit")
tempobj.disabled=!checkobj.checked
}
}
}
function defaultagree(el){
if (!document.all&&!document.getElementById){
if (window.checkobj&&checkobj.checked)
return true
else{
alert("Please accept terms to submit form")
return false
}
}
}
function Validatie ( form )
{
  if (form.klantEmail.value == "") {
    alert( "uw emailadres a.u.b." );
    form.klantEmail.focus();
    return false ;
  }
  
 if (form.klantNaam.value == "") {
    alert( "uw Naam a.u.b." );
    form.klantNaam.focus();
    return false ;
  }
  
  if (form.paswoord.value == "") {
    alert( "uw paswoord a.u.b." );
    form.paswoord.focus();
    return false ;
  }
  
    if (form.klantstraat.value == "") {
    alert( "uw straat a.u.b." );
    form.klantstraat.focus();
    return false ;
  }
  
    if (form.klantstraatnr.value == "") {
    alert( "het Huisnummer a.u.b." );
    form.klantstraatnr.focus();
    return false ;
  }
  
   if (form.klantstad.value == "") {
    alert( "uw stad a.u.b." );
    form.klantstad.focus();
    return false ;
  }
  
  if (form.klantpostcode.value == "") {
    alert( "uw postcode a.u.b." );
    form.klantpostcode.focus();
    return false ;
  }

    if (form.klantTelefoon.value == "") {
    alert( "uw telefoon a.u.b." );
    form.klantTelefoon.focus();
    return false ;
  }
  

  return true ;
}
