function checkFieldsContactForm(){
    if ((document.getElementById('naam').value != "") && (document.getElementById('email').value != "")) {
        return true;            
    } else {
        alert("Niet alle velden zijn correct ingevuld !");
        return false;
    }
}

function OpenWin(mypage,myname,w,h,features) {
    if(screen.width){
    var winl = (screen.width-w)/2;
    var wint = (screen.height-h)/2;
    }else{winl = 0;wint =0;}
    if (winl < 0) winl = 0;
    if (wint < 0) wint = 0;
    var settings = 'height=' + h + ',';
    settings += 'width=' + w + ',';
    settings += 'top=' + wint + ',';
    settings += 'left=' + winl + ',';
    settings += features;
    win = window.open(mypage,myname,settings);
    win.window.focus();
}      

function checkNieuwsbrief() {
	var sOut = "De volgende velden zijn incorrect:\n";
	var bResult = true;
	if (document.getElementById('email').value == '') {
		sOut += 'E-mail adres\n';
		bResult = false;
	}
	if (!bResult) {
		alert(sOut);
	}
	return bResult;	
}

function changePage() {
	if (self.parent.frames.length != 0) {
		self.parent.location=document.location;
	}
}

function init() {
//		params = 'affid=gh01&c=VRZK_GHD';
	new Ajax.Updater('offertForm', 'public/form.php', {asynchronous: true,evalScripts:true});  
}


function showContact() {
//   new Effect.Fade('dvText', {from: 1, to: 0});
//	  new Effect.SlideUp('dvSlideBlock', {duration: 0.0});
  new Effect.Appear('dvBlock', {from: 0, to: 1});
  new Effect.SlideDown('dvBlock', {duration: 0.8});
}

function hideContact() {
  //new Effect.SlideUp('dvSlideBlock', {duration: 0.0});
 // new Effect.Fade('dvText', {from: 0, to: 1});
  new Effect.SlideUp('dvBlock', {duration: 0.8});
  new Effect.Appear('dvBlock', {from: 1, to: 0});
}        

function showOfferteForm() {
  new Effect.Appear('dvOfferteBlock', {from: 0, to: 1});
  new Effect.SlideDown('dvOfferteBlock', {duration: 0.8});
}

function hideOfferteForm() {
  new Effect.SlideUp('dvOfferteBlock', {duration: 0.8});
  new Effect.Appear('dvOfferteBlock', {from: 1, to: 0});
}        

function OpenWin(mypage,myname,w,h,features) {
	if(screen.width){
	var winl = (screen.width-w)/2;
	var wint = (screen.height-h)/2;
	}else{winl = 0;wint =0;}
	if (winl < 0) winl = 0;
	if (wint < 0) wint = 0;
	var settings = 'height=' + h + ',';
	settings += 'width=' + w + ',';
	settings += 'top=' + wint + ',';
	settings += 'left=' + winl + ',';
	settings += features;
	win = window.open(mypage,myname,settings);
	win.window.focus();
}

function logOff() {
document.location='/beheer/index.php?logout=true';
}

var indMenuDown = false;

function dropmenu() {
  document.getElementById('dropdownMenu').style.display='block';
  indMenuDown = false; 
}

function dropmenuUp() {
  if (indMenuDown) {
      document.getElementById('dropdownMenu').style.display='none';
      indMenuDown = false; 
  }
}

function loadFrame() {
	location.href="#top";
}