/*
	This script file contains global scripts for
	use throughout the site, basic behaviour 
	assignment and other bits and pieces.
*/

// Work out how far down the page the footer should appear
function shoveFooter() {
	if (!document.getElementById) return;
	var sb = document.getElementById('sidebar');
	if (!sb) return;
	var sh = sb.scrollHeight;
	var main = document.getElementById('main');
	var mh = main.scrollHeight+350;
	if (sh > mh) main.style.height = (sh+15)+'px';
}

addEvent(window,'load',shoveFooter);