function checkUser() {
var d = document.forms.contact;

   if (d.m_naam.value==""){
                alert('U bent vergeten om uw naam in te vullen!');
                d.m_naam.focus();
                return false;
 }
   if (d.m_email.value==""){
                alert('U bent vergeten om uw email adres in te vullen!');
                d.m_email.focus();
                return false;
 }
        if (!isEmail(d.m_email.value)){
                window.alert("Uw email adres is niet correct in gevuld!");
                d.m_email.focus();
                return false;
 }

}
function checkContact() {
var d = document.forms.contact;

   if (d.m_voornaam.value==""){
                alert('U bent vergeten om uw naam in te vullen!');
                d.m_voornaam.focus();
                return false;
 }
 
    if (d.m_achternaam.value==""){
                alert('U bent vergeten om uw achternaam in te vullen!');
                d.m_achternaam.focus();
                return false;
 }
   if (d.email.value==""){
                alert('U bent vergeten om uw email adres in te vullen!');
                d.email.focus();
                return false;
 }
        if (!isEmail(d.email.value)){
                window.alert("Uw email adres is niet correct in gevuld!");
                d.email.focus();
                return false;
 }

}

function isEmail(str) {
  // are regular expressions supported?
  var supported = 0;
  if (window.RegExp) {
    var tempStr = "a";
    var tempReg = new RegExp(tempStr);
    if (tempReg.test(tempStr)) supported = 1;
  }
  if (!supported)
    return (str.indexOf(".") > 2) && (str.indexOf("@") > 0);
  var r1 = new RegExp("(@.*@)|(\\.\\.)|(@\\.)|(^\\.)");
  var r2 = new RegExp("^.+\\@(\\[?)[a-zA-Z0-9\\-\\.]+\\.([a-zA-Z]{2,3}|[0-9]{1,3})(\\]?)$");
  return (!r1.test(str) && r2.test(str));
}

startList = function() {

	//code only for IE
	if(!document.body.currentStyle) return;
	var subs = document.getElementsByName('submenu');
	for(var i=0; i<subs.length; i++) {
		var li = subs[i].parentNode;
		if(li && li.lastChild.style) {
			li.onmouseover = function() {
				this.lastChild.style.visibility = 'visible';
			}
			li.onmouseout = function() {
				this.lastChild.style.visibility = 'hidden';
			}
		}
	}
}
window.onload=startList;

