// 	#####################################################################
// 	# Provides capability to add multiple onload events
//	# Original found on tek-tips.com (author unknown)
// 	#####################################################################
	function addOnloadEvent(fnc){

		if ( typeof window.addEventListener != "undefined" ) {

			window.addEventListener( "load", fnc, false );

		} else if ( typeof window.attachEvent != "undefined" ) {

			window.attachEvent( "onload", fnc );

		} else {

			if ( window.onload != null ) {

				var oldOnload = window.onload;

				window.onload = function ( e ) {

					oldOnload( e );

					window[fnc]();

				};

			} else {

				window.onload = fnc;

			}

		}

	}


// 	#####################################################################
// 	# Popup window
// 	#####################################################################
	function popWin(url, width, height, name) {

		xPos = (screen.width / 2) - (width / 2);
		yPos = (screen.height / 2) - (height / 2);

		attr	= 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,'
				+ 'width=' + width + ','
				+ 'height=' + height + ','
				+ 'left=' + xPos + ','
				+ 'top=' + yPos;

		var win = window.open(url, name, attr);
		win.focus();

	}
