
function fixFooter() 
{
	if (document.getElementById) 
	{
		var footerNode = document.getElementById('footer');
		footerNode.style.display = 'none';	

		// the divs array contains references to each column's div element.  
		var divs = new Array
			(
				document.getElementById('maincontent'), 
				document.getElementById('leftnav')
			);		
		// Let's 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;
			}
		}
		// Resize the content node
		var contentNode = document.getElementById('threecolumn');
		contentNode.style.height = maxHeight  + 'px';
		
		// Show the footer as it should initially be hidden
		// This prevents the footer from moving onload
		footerNode.style.display = 'block';	
	}
}
  
window.onload = fixFooter;
window.onresize = fixFooter;
  
