/**
 *
 */
function popUp(url, name, features)
{
    features += ",resizable=1,directories=0,menubar=0,status=0,toolbar=0";
    if (popUpWindow && ! popUpWindow.closed) { popUpWindow.close(); }
    var popUpWindow = window.open("", name, features);
    popUpWindow.location.href = url;
    popUpWindow.focus();
    if (popUpWindow.opener == null) { popUpWindow.opener = self; }
}

/**
 *
 */
function popUpPrint(url, name, features)
{
    features += ",resizable=1,directories=0,menubar=1,status=0,toolbar=0";
    if (popUpWindow && !popUpWindow.closed) { popUpWindow.close(); }
    var popUpWindow = window.open("", name, features);
    popUpWindow.location.href = url;
    popUpWindow.focus();
    if (popUpWindow.opener == null) { popUpWindow.opener = self; }
}

/**
 *
 */
function closePopUp(popUpWindow)
{
    if (popUpWindow.opener && ! popUpWindow.opener.closed) { popUpWindow.opener.focus(); }
    popUpWindow.close();
}
