﻿function getItem(id) {
    var itm = false;
    if (document.getElementById)
        itm = document.getElementById(id);
    else if (document.all)
        itm = document.all[id];
    else if (document.layers)
        itm = document.layers[id];

    return itm;
}
function hideItems() {
    itm = getItem("metier");
    itm.style.display = 'none';
    itm = getItem("qui");
    itm.style.display = 'none';

}
function toggleItem(id) {
    hideItems();
    itm = getItem(id);
    if (!itm)
        return false;
    itm.style.display = '';
    return false;
}
function checkPage() {
    var temp = getItem("cat");
    if (temp != null) {
        var itm = getItem(temp.value);
        hideItems();
        if (itm != null) itm.style.display = '';
    }
    //check hoofdlink
    var temp2 = getItem("head");
    if (temp2 != null) {
        var headItem = getItem(temp2.value);
        if (headItem != null) {
            headItem.style.backgroundColor = "#003888";
            headItem.style.color = "White";
        }
    }
    //check subnavigatie
    var temp3 = getItem("link");
    if (temp3 != null) {
        var linkItem = getItem(temp3.value);
        if (linkItem != null) linkItem.style.color = "#a02118";
    }
}