// disp_wth is the maximum size to which a page will expand
// Usability studies indicate that readability becomes difficult at widths greater than 1000px
var disp_wth = 1000;
var l_off = 0;
var wth = 0;

function reloadPage () {
	var tmp = getX("right_side");
	if (tmp != disp_wth) {
		disp_wth = tmp;
		setTimeout('resizeIt()',250);
		}
	}
	
function resizeIt (area) {
	var max_wth = 950;
	document.getElementById ('container').style.visibility='hidden';
	disp_wth = getX ("right_side");
	if (disp_wth > (max_wth + 20)) {
		document.getElementById("container").style.width = max_wth + 'px';
		var offset = disp_wth - (max_wth + 20);
		offset = Math.floor (offset / 2);
		document.getElementById("container").style.marginLeft = offset + 'px';
		l_off = offset + 'px';
		wth = max_wth + 'px';
		}
	else {
		document.getElementById("container").style.width = "100%";
		document.getElementById("container").style.marginLeft = 0 + 'px';
		l_off = '0px';
		wth = '100%';
		}
	document.getElementById ('container').style.visibility='visible';
	}

function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
	}