/**
 * add multiple JavaScript onload functions
 * @function
 */ 
function addLoadEvent(func) {
	var oldonload = window.onload;
	if (typeof window.onload != 'function') {
		window.onload = func;
	} else {
		window.onload = function() {
			if (oldonload) {
				oldonload();
			}
			func();
		}
	}
}

// prevent user from selecting html text
// corrects the bug w/ the scrollbar in IE (white box displays upon text selection or scrolling)

function disabletext(e) {
	return false  
}  
  
function reEnable() {
	return true  
}  
  
//if the browser is IE4+

function stopSelection(id) {
	document.getElementById(id).onselectstart=new Function ("return false")  
	  
	//if the browser is NS6  
	if (window.sidebar){  
	document.getElementById(id).onmousedown=disabletext  
	document.getElementById(id).onclick=reEnable  
	}
}
 

