function company(){
   if ((w1.length == "") || (w1.length < 2)) { 
                return false; 
  }
  return true;
}
function name_first_sur(){
   if ((w2.length == "") || (w2.length < 2)) { 
                return false; 
  }
  return true;
}
function street(){
   if ((w3.length == "") || (w3.length < 2)) { 
                return false; 
  }
  return true;
}
function zipcode(){
   if ((w4.length == "") || (w4.length < 2)) { 
                return false; 
  }
  return true;
}
function country(){
   if ((w5.length == "") || (w5.length < 2)) { 
                return false; 
  }
  return true;
}
function phone(){
   if ((w6.length == "") || (w6.length < 2)) { 
                return false; 
  }
  return true;
}
//funktion til validering af email adresse
function e_mail_validering() 
{ 

    if (e1.length < 6) { 
        alert("You have not entered a correct e-mail address."); 
        document.kontakt.email.focus(); //tjekker for manglende tegn (min 6 tegn)
        return false; 
    } 
e2 = e1.split("@")
     
    if (!(e2.length == 2 && e2[0].length > 0 && e2[1].length > 0)){ 
        alert("You have not entered a correct e-mail address."); 
        document.kontakt.email.focus(); //tjekker for manglende tegn 
        return false; 
    } 

     
    e3 = e2[1].split(".")
	   e3l = e3.length;
    if (e3l < 2 ){ 
        alert("You have not entered a correct e-mail address."); 
        document.kontakt.email.focus();; //tjekker for manglende punktum
        return false; 
    } 

    for (t=0; t<e3l; t++) { 
        if (e3[t].length == 0) { 
            alert("You have not entered a correct e-mail address."); 
            document.kontakt.email.focus(); //tjekker for manglende domæne
            return false; 
         } 
        if (t == (e3l)) { 
            if (e3[t].length < 1) { 
                alert("You have not entered a correct e-mail address."); 
                document.minform.e_mail.focus(); //tjekker for manglende topdomæne
                return false; 
             } 
        } 
    } 
return true; 
}     

