var oMoreWindow=null;
function showMoreWindow(strPageId) 
{
    var sid=null;
    var iWindowWidth=500;
    var iWindowHeight=525;
    var strFeatures='';
    
    strFeatures+='scrollbars=yes,resizable=yes,directories=no,status=no,toolbar=no,menubar=no,';
    strFeatures+='top='+(((screen.height-iWindowHeight)/2)+(-50))+'px,';
    strFeatures+='left='+((screen.width-iWindowWidth)/2)+'px,';
    strFeatures+='width='+iWindowWidth+'px,';
    strFeatures+='height='+iWindowHeight+'px';
    
    if (!strPageId || strPageId==='')
    {
        if (hasQueryVariable(document.URL,'p'))
        {
            strPageId=getQueryVariable(document.URL,'p');
        }        
    }
    if (hasQueryVariable(document.URL,'sid'))
    {
        sid=getQueryVariable(document.URL,'sid');
    }
    if (strPageId!=null) 
    {
        if (sid)
        {
            strPageId+='&sid='+sid;
        }
        oMoreWindow=window.open('pagedetail.php?p='+strPageId,'LearnMore',strFeatures);
    } 
    else 
    {
        oMoreWindow=window.open('pagedetail.php','LearnMore',strFeatures);    
    }
}
function showCursor(strCursor) 
{
    if (strCursor!=null && document!=null && document.body!=null) 
    {
        document.body.style.cursor=strCursor;
    }
}
function getQueryVariable(url,key) 
{
	if (url.indexOf('?')<0) { return ''; }
	var queryStrings=url.substring(url.indexOf('?')+1, url.length);
	var vars=queryStrings.split("&");
	for (var i=0;i<vars.length;i++)	
	{
		var pair=vars[i].split("=");
		if (pair[0].toUpperCase()==key.toUpperCase()) 
		{
			return pair[1];
		}
	}
}
function hasQueryVariable(url,key) 
{
	if (url.indexOf('?')<0) { return false; }
	var queryStrings=url.substring(url.indexOf('?')+1, url.length);
	var vars=queryStrings.split("&");
	for (var i=0;i<vars.length;i++)	
	{
		var pair=vars[i].split("=");
		if (pair[0].toUpperCase()==key.toUpperCase()) 
		{
			return true;
		}
	}
	return false;
}