/*********** general functions  **********/

function openProduct(productPath, windowName)
{
    window.open(productPath, windowName, 'height=700,width=800,menubar=no,toolbar=no,resizable=1,scrollbars=yes');
}

function openPopup(path, windowName)
{
    window.open(path, windowName, 'height=700,width=900,menubar=no,toolbar=no,resizable=1,scrollbars=yes');
}

function openContact(contactPath, windowName)
{
    window.open(contactPath + "?popup=1", windowName, 'height=300,width=450,menubar=no,toolbar=no,resizable=1,scrollbars=yes');
}

function printVersion(itemPath, windowName)
{
    if (itemPath == "/") itemPath = "/Home.aspx";
    itemPath += window.location.search;    
    if (itemPath.indexOf("p=1") < 0)
    {
        if (itemPath.indexOf("?") < 0) itemPath += "?"
        else itemPath += "&";
        itemPath += "p=1";
    }
    window.open(itemPath, windowName, 'height=700,width=700,menubar=no,toolbar=no,resizable=1,scrollbars=yes');
}

function closeWindow()
{
    window.close();
}

function printWindow(sourceID)
{
    var printHref = document.getElementById(sourceID);
    printHref.style.display = "none";
    window.print();
    printHref.style.display = "inline";
}
/*****************************************************************/



/*********** functions for close button at bottom right **********/
function setVariables() 
{
    if (navigator.appName == "Netscape") 
    {
        dS="document.";
        sD="";
    }
    else 
    {
        dS="";
        sD=".style";
    }
}

function checkLocation() 
{

    timerID = setTimeout("checkLocation()",3000);
    
    alert(document.getElementById("closewindowbutton").style.bottom);/*
    document.getElementById("closewindowbutton").style.bottom = parseInt(document.getElementById("closewindowbutton").style.bottom) + 5 + "px";
    */
    /*
    object="closewindowbutton";
    eval("alert(document.getElementById('"+object+"').style.bottom)");//+sD+".left)");
    eval("document.getElementById('"+object+"')"+sD+".bottom='1'+document.getElementById('"+object+"')"+sD+".bottom");*/
    /*
    eval("document.getElementById('"+object+"')"+sD+".bottom='0px'");
    eval("document.getElementById('"+object+"')"+sD+".bottom='1px'");
    eval("document.getElementById('"+object+"')"+sD+".bottom='0px'");
    */
    document.getElementById("closewindowbutton").style.bottom = "1px";
    document.getElementById("closewindowbutton").style.bottom = "2px";
    document.getElementById("closewindowbutton").style.bottom = "1px";
    /*
    eval(dS+object+sD+".bottom=0");
    eval(dS+object+sD+".bottom=1");
    eval(dS+object+sD+".bottom=0");*/
}

/*****************************************************************/


