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();
}
MM_reloadPage(true);

function MM_checkBrowser(NSvers,NSpass,NSnoPass,IEvers,IEpass,IEnoPass,OBpass,URL,altURL) { //v4.0
  var newURL='', verStr=navigator.appVersion, app=navigator.appName, version = parseFloat(verStr);
  if (app.indexOf('Netscape') != -1) {
    if (version >= NSvers) {if (NSpass>0) newURL=(NSpass==1)?URL:altURL;}
    else {if (NSnoPass>0) newURL=(NSnoPass==1)?URL:altURL;}
  } else if (app.indexOf('Microsoft') != -1) {
    if (version >= IEvers || verStr.indexOf(IEvers) != -1)
     {if (IEpass>0) newURL=(IEpass==1)?URL:altURL;}
    else {if (IEnoPass>0) newURL=(IEnoPass==1)?URL:altURL;}
  } else if (OBpass>0) newURL=(OBpass==1)?URL:altURL;
  if (newURL) { window.location=unescape(newURL); document.MM_returnValue=false; }
}
//-->

function popUp(URL) {
	day = new Date();
	id = day.getTime();
	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=yes,location=0,statusbar=0,menubar=0,resizable=0,width=517,height=400,left = 10,top = 10');");
}

var aw;
var ah;
var is800 = false;
var res;

aw = document.body.offsetWidth;
is800 = false;
if (aw <= 800) {
	is800 = true;
}

window.onload = onloevha;
window.onresize = myonresize;

function onloevha(){
	//MM_checkBrowser(4.0,1,0,4.0,0,1,1,'index_netscape.htm','');
	fixsizes();
	return document.MM_returnValue;
}

function myonresize() {
	location.reload();
//	fixsizes();
}

function fixsizes() {
	window.onresize = myonresize;

	aw = document.body.offsetWidth;
	ah = document.body.offsetHeight;

	is800 = false;
	res = "1024";
	if (aw <= 800) {
		is800 = true;
		res = "800";
	}

	footHeight = (is800 ? 8 : 10);
	topHeight = (is800 ? 130 : 175);
	menuWidth = (is800 ? 235 : 300);
	mainLeft = (is800 ? 12 : 15);
	marge1 = (is800 ? 10 : 8);

	if (menuDiv) {
		menuDiv.style.pixelLeft = aw - menuWidth - 4;
		menuDiv.style.pixelHeight = ah - topHeight - marge1 - footHeight;
		menuDiv.style.pixelWidth = menuWidth;
		menuDiv.style.pixelTop = topHeight - 2;
	}
	if (mainDiv) {
		mainDiv.style.pixelWidth = aw - mainLeft - menuWidth - 2;
		mainDiv.style.pixelHeight = ah - topHeight - marge1 - footHeight;
		mainDiv.style.pixelLeft = mainLeft;
		mainDiv.style.pixelTop = topHeight;
	}
	if (textDiv) {
		textDiv.style.pixelHeight = mainDiv.style.pixelHeight;
	}
	if (footDiv) {
		footDiv.style.pixelWidth = aw - 4;
		footDiv.style.pixelTop = ah - footHeight - marge1;
		document.footImg.height = footHeight;
	}
	document.compassImg.src = 'images/compass' + res + '.jpg';
	document.compassImg.width = (is800 ? 593 : 760);
	document.compassImg.height = topHeight;
	document.body.style.backgroundImage = 'url(images/background_page' + res + '.gif)';
	document.all.menuTd.style.backgroundImage = 'url(images/' + menubgimage + '_' + res + '.jpg)';
	document.all.menuTd.style.paddingTop = is800 ? 185 : 229;
}
