//makes window.onload non-destructive, ensuring that various functions can happen during the event
//MUST add addLoadEvent(NameOfFunction); after every function that relys on the windo.onload event
//there are other ways to handle this, such as in an array, but I left it this way for cleaner code readability -- Matthew Wilson 07/13/2011
function addLoadEvent(func) {
    var oldonload = window.onload;
    if (typeof window.onload != 'function') {
        window.onload = func;
    }
    else {
        window.onload = function() {
                oldonload();
                func();
            };
		}
};
