// Popup window code for image viewer
// St Emlyn's
// (C) 2003 Seven Communications Ltd

// Open popup window (URL, width, height)
function openPopup (winUrl, winWidth, winHeight)
    {
    var newWindow=window.open(winUrl,"imageWindow","width="+winWidth+",height="+winHeight+",location=no,menubar=no,scrollbars=yes,status=no,resizable=no,toolbar=no");
    newWindow.focus();
    }

function jsPopup (winUrl, winWidth, winHeight, location, menu, scrollbar, status, resize, tools, top, left)
    {
    if (! window.focus) return true;

    var winLocation;
    if (typeof (winUrl) == 'string')
        { winLocation = winUrl; }
    else
        { winLocation = winUrl.href; }

    var newWindow=window.open(winLocation,"popupWindow","width="+winWidth+",height="+winHeight+",top="+top+",left="+left+"location="+location+",menubar="+menu+",scrollbars="+scrollbar+",status="+status+",resizable="+resize+",toolbar="+tools);
    newWindow.focus();

    return false;
    }
