// by Paul@YellowPencil.com and Scott@YellowPencil.com

function setTall() {
	if (document.getElementById) {
		// the divs array contains references to each column's div element
		var divs = new Array(document.getElementById('pagenav'), document.getElementById('leftside'), document.getElementById('rightside'));
		
		// determine the maximum height out of all columns specified
		var maxHeight = 0;
		for (var i = 0; i < divs.length; i++) {
			if (divs[i].offsetHeight > maxHeight) maxHeight = divs[i].offsetHeight;
		}
		
		// set all columns to maximum height
		for (var i = 0; i < divs.length; i++) {
			divs[i].style.height = maxHeight + 'px';

			// if the browser's working in standards-compliant mode, the height property
			// sets the height excluding padding, so we figure the padding out by subtracting the
			// old maxHeight from the new offsetHeight, and compensate!
			if (divs[i].offsetHeight > maxHeight) {
				divs[i].style.height = (maxHeight - (divs[i].offsetHeight - maxHeight)) + 'px';
			}
		}
	}
}


