function checkForm(formulier) {
    if(formulier.name.value == '') {
        alert("U hebt geen naam ingevuld.");
        formulier.name.focus();
        return false;
    }
    else if(formulier.email.value == '') {
        alert("U hebt geen e-mailadres ingevuld.");
        formulier.email.focus();
        return false;
    }
    else if(formulier.message.value == '') {
        alert("U hebt geen bericht ingevuld.");
        formulier.message.focus();
        return false;
    }
    else {
        return true;
    }
}

var popUpWin;

function openCentered(documentSrc, windowWidth, windowHeight,scrBars,res) {
    var resizable = (res != null) ? res : 0;

    if(popUpWin){
        if(!popUpWin.closed) popUpWin.close();
    }

    windowLeft = (window.screen.width  - windowWidth)  >> 1;
    windowTop  = (window.screen.height - windowHeight) >> 1;

    popUpWin = window.open(documentSrc, '','toolbar=0,channelmode=0,location=0,menubar=0,resizable=' + resizable + ',status=0,scrollbars=' + scrBars + ',width=' + windowWidth + ',height=' + windowHeight + ',left=' + windowLeft + ',top=' + windowTop);
    popUpWin.focus();

    return popUpWin;
}

function popup(documentSrc) {
    return openCentered(documentSrc, 600, 500, 1, 1);
}