/**
 * This file contains utility functions that should be included on any page
 * that uses any javascript on the site
 */

/**
 * This is the function that should be used to add functions that are called
 * on page load (initialization functions).  window.onload should not be
 * assigned directly!
 */
function addLoadEvent(func) {
	var oldonload = window.onload;
	if (typeof window.onload != 'function') {
		window.onload = func;
	}
	else {
		window.onload = function() {
			oldonload();
			func();
		}
	}
}