﻿//nid = page, querystring = params, width of window, height of window
function showDialog(nid,querystring,width,height)
{
    var forward = "?nid=" + nid + "&w="+width+"&h="+height + querystring;  
    var features = "dialogWidth:"+width+"px;dialogHeight:"+height+"px;scroll:no;";
    var modal = window.showModalDialog(gModalPath+forward,this,features);   
}
function autoIframe()
{
    try
    {
        frame = window[0];
        innerDoc = frame.document;
        //alert(innerDoc.body.scrollHeight);
        //frame.height = innerDoc.body.scrollHeight + 10;
        document.getElementById("divFrameEdit").style.height = (innerDoc.body.scrollHeight + 10);
    }
    catch(err)
    {
        window.status = err.message;
    }
}

function togglePanel(id)
{
    if(document.getElementById(id).style.display == "none")
    {
        document.getElementById(id).style.display = "";
    }
    else
    {
        document.getElementById(id).style.display = "none";
    }
    return false;
}
function togglePanelDirection(id,display)
{
    if(display)
    {
        document.getElementById(id).style.display = "";
    }
    else
    {
        document.getElementById(id).style.display = "none";
    }    
}
function mouseOver(item)
{
    item.style.cursor = "pointer";
}
function mouseOut(item)
{
    item.style.cursor = "";
}