var navRefOne = "";
var navRefTwo = "";

if (document.layers) {
	navRefOne = "document.layers[";
	navRefTwo = "]";
	
}  else if (document.getElementById && !document.all) {
	navRefOne = "document.getElementById(\'";
	navRefTwo = "\')";
	
} else if (document.all) {
	navRefOne = "document.all.";
	navRefTwo = "";
}
var drawFooter = false;
var maxLRHeight, maxHeight;

function evenColumnHeights() {
	var leftHeight = eval(navRefOne + "leftColumn" + navRefTwo + ".offsetHeight");
	var rightHeight = eval(navRefOne + "rightColumn" + navRefTwo + ".offsetHeight");
	var centerHeight = eval(navRefOne + "centerColumn" + navRefTwo + ".offsetHeight");
	
	maxLRHeight = Math.max(leftHeight, rightHeight);
	maxHeight = Math.max(centerHeight, maxLRHeight);
	
	eval(navRefOne + "leftColumn" + navRefTwo + ".style.height=\"" + maxHeight + "px\"");
	eval(navRefOne + "rightColumn" + navRefTwo + ".style.height=\"" + maxHeight + "px\"");
	eval(navRefOne + "centerColumn" + navRefTwo + ".style.height=\"" + maxHeight + "px\"");
}

function checkColumnHeights() {
	var centerContentHeight = (eval(navRefOne + "centerColumnContent" + navRefTwo + ".offsetHeight"));
	if (centerContentHeight > maxHeight) {
		maxHeight = centerContentHeight;
		eval(navRefOne + "leftColumn" + navRefTwo + ".style.height=\"" + maxHeight + "px\"");
		eval(navRefOne + "rightColumn" + navRefTwo + ".style.height=\"" + maxHeight + "px\"");
		eval(navRefOne + "centerColumn" + navRefTwo + ".style.height=\"" + maxHeight + "px\"");
	} else if (centerContentHeight < maxHeight && centerContentHeight > maxLRHeight) {
				eval(navRefOne + "leftColumn" + navRefTwo + ".style.height=\"" + centerContentHeight + "px\"");
				eval(navRefOne + "rightColumn" + navRefTwo + ".style.height=\"" + centerContentHeight + "px\"");
				eval(navRefOne + "centerColumn" + navRefTwo + ".style.height=\"" + centerContentHeight + "px\"");
	} else if (centerContentHeight < maxLRHeight) {
				eval(navRefOne + "leftColumn" + navRefTwo + ".style.height=\"" + maxLRHeight + "px\"");
				eval(navRefOne + "rightColumn" + navRefTwo + ".style.height=\"" + maxLRHeight + "px\"");
				eval(navRefOne + "centerColumn" + navRefTwo + ".style.height=\"" + maxLRHeight + "px\"");
	}
}

window.onload = function() { evenColumnHeights(); }
window.onresize = function() { checkColumnHeights(); }
