<!--

//get the height of the window for all browsers

function getWindowHeight() {
     var windowHeight = 0;
     if (typeof(window.innerHeight) == 'number') {
          windowHeight = window.innerHeight;
     }
     else {
          if (document.documentElement && document.documentElement.clientHeight) {
               windowHeight = document.documentElement.clientHeight;
          }
          else {
               if (document.body && document.body.clientHeight) {
                    windowHeight = document.body.clientHeight;
               }
          }
     }
     return windowHeight;
}

//set the height of the content box but only if the content within exceeds the height of the window

function setMain() {
     if (document.getElementById) {
          var windowHeight = getWindowHeight();
          if (windowHeight > 0) {

               // how tall is the header?
               var headerHeight = document.getElementById('header').offsetHeight;

               // how tall is the content area?
               var contentElement = document.getElementById('bodyContent');
               var contentHeight  = contentElement.offsetHeight;

               //how tall is the footer?
               var footerHeight = document.getElementById('footer').offsetHeight;

               //now lets get everything to line up...
			   
			   var totalHeight = ((windowHeight - (headerHeight + footerHeight))-40)


				if ((contentHeight + headerHeight) < windowHeight) {
               contentElement.style.height = totalHeight + 'px';
				}
          }
     }
}

//Set window height

window.onload = function()
{
     setMain();
}

window.onresize = function()
{
     setMain();
}

function decision(message, url){

	if(confirm(message)) location.href = url;
}

function openWin(winUrl,winWidth,winHeight) {

	window.open(winUrl, "helpPopup", "toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width=" + winWidth + ", height=" + winHeight + ",top=50,left=50");
	
	return true;

}

// -->


