﻿function openvenster(url, popup_width, popup_height, scrollbars) {

    var undefined;

    if (popup_width == undefined) popup_width = 800;

    if (popup_height == undefined) popup_height = 600;

    if (scrollbars == undefined) scrollbars = 'no';

    left_pos = (screen.availWidth / 2) - (popup_width / 2);

    top_pos = (screen.availHeight / 2) - (popup_height / 2);

    window.open(url, 'popup', 'height=' + popup_height + ',left=' + left_pos + ',width=' + popup_width + ',scrollbars=' + scrollbars);

}



function toonOverlay(url) {

    var elOverlay = document.getElementById("overlayHotels");



    if (url != -1) {

        document.getElementById("overlayFrame").src = url;

    }



    if (url != "" || url == -1) {

        elOverlay.style.visibility = "visible";

    } else {

        elOverlay.style.visibility = "hidden";

    }

}



function getOffsetLeft(el, p) {

    var ol = el.offsetLeft;

    while ((el = el.offsetParent) != null) {

        ol += el.offsetLeft;

    }

    return ol;

}