function hideAllDivs(){
  objElement = document.getElementById('connected').style;
  objElement.display = "none";
  objElement = document.getElementById('enhanced').style;
  objElement.display = "none";
  objElement = document.getElementById('empowered').style;
  objElement.display = "none";
}

function showDiv(strDivName){
  hideAllDivs();
  objElement = document.getElementById(strDivName).style;
  objElement.display = "";
}

function displayNav(strNav,action){
  objElement = document.getElementById(strNav).style;
  if(action=='show'){
	  objElement.display = "";
  } else if(action=='hide') {
	  objElement.display = "none";
  }
}

function retVal(sName)
{
  var sURL = new String(window.location);
  var iQMark= sURL.lastIndexOf('?');
  var iLensName=sName.length;
  
  //retrieve loc. of sName
  var iStart = sURL.indexOf('?' + sName +'=') //limitation 1
  if (iStart==-1)
        {//not found at start
        iStart = sURL.indexOf('&' + sName +'=')//limitation 1
		if (iStart==-1)
		   {//not found at end
		    return 0; //not found
		   }   
        }
        
  iStart = iStart + + iLensName + 2;
  var iTemp= sURL.indexOf('&',iStart); //next pair start
  if (iTemp ==-1)
		{//EOF
		iTemp=sURL.length;
		}  
  return sURL.slice(iStart,iTemp ) ;
  sURL=null;//destroy String
}

var param = retVal('print');
var cssfile = (param==1)? "res/styles_print.css" : "res/styles.css"; 
document.write('<link href="'+cssfile+'" type="text/css" rel="stylesheet">'); 

function displayPrintBt(pr){
	objElement = document.getElementById('printv').style;
	if(pr==0){
		objElement.display = "block";
	}
}

function displayPrintVersion(){
	var pageURL = new String(window.location) + '?print=1';
	location.href=pageURL;
}

