HTTP_GET_VARS=new Array();
strGET=document.location.search.substr(1,document.location.search.length);
if(strGET!='')
    {
    gArr=strGET.split('&');
    for(i=0;i<gArr.length;++i)
        {
        v='';vArr=gArr[i].split('=');
        if(vArr.length>1){v=vArr[1];}
        HTTP_GET_VARS[unescape(vArr[0])]=unescape(v);
        }
    }

function get(v)
{
if(!HTTP_GET_VARS[v]){return 'undefined';}
return HTTP_GET_VARS[v];
}

function popup(url, title, width, height) {
window.open( url, title, "status = 1, height = "+height+", width = "+width+", resizable = 0" )
}

function toggleAddTable(id) {
var e = document.getElementById(id);
        if(e.style.display == 'block') {
            e.style.display = 'none';
        }
        else {
            e.style.display = 'block';
        }


}

function showErrorPopup(title, text, confirm_button) {
document.getElementById('disable_div').style.display = 'block';
document.getElementById('warning_popup').style.display = 'block';
document.getElementById('warning_title').innerHTML = title;
document.getElementById('warning_text').innerHTML = text;
document.getElementById('warning_popup_confirm').innerHTML = confirm_button;
}

function performAction(url) {
	hideErrorPopup();
	window.location.href = url;
}

function hideErrorPopup() {
document.getElementById('disable_div').style.display = 'none';
document.getElementById('warning_popup').style.display = 'none';
}