//-- (c) 2006 Zicht nieuwe media ontwerpers BV --//
//--          http://www.zicht.nl              --//


//-- achtergrondkleur van body veranderen
function changeBodyBgColor(_color) {
    document.body.style.backgroundColor = _color;
}

//-- div hiden of showen
function toggleDiv(_obj, _id) {
    
    if (document.getElementById(_id).style.display == 'block') {
        document.getElementById(_id).style.display = 'none';
    } else {
        document.getElementById(_id).style.display = 'block';
    }
    
    txt = _obj.innerHTML;
    if (/\+/.test(txt)) {
        _obj.innerHTML = txt.replace('+', '-');
    } else {
        _obj.innerHTML = txt.replace('-', '+');
    }
}

//-- routeplanner window openen
function openRoutePlanner() {
    
    if (screen.width == 1024 && screen.height == 768) {
        //-- 1024 x 768
        _w = 868;
        _h = 651;
    } else if (screen.width > 1024 && screen.height > 800) {
        //-- 1280 x 1024 & bigger
        _w = 1024;
        _h = 768;
    } else if (screen.width > 1024 && screen.height <= 800) {
        //-- 1280 x 800 etc, widescreens
        _w = 868;
        _h = 651;
    } else {
        //-- default small
        _w = 720;
        _h = 540;
    }
    
    var windowRP = window.open('/routeplanner/index-test.html', 'windowRP', 'width=' + _w + ',height=' + _h + ',left=0,top=0,scrollbars=no,resizable=no');
}

