function WriteFlash (strFile, strID, intWidth, intHeight, arParams, strAltHTML)
{
	if (navigator.userAgent.indexOf("MSIE") != -1) {
		document.write ('<object id="'+strID+'" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"');
		document.write ('codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0"');
		document.write ('width="'+intWidth+'"');
		document.write ('height="'+intHeight+'">');
	} else {
		document.write ('<object id="'+strID+'" data="'+strFile+'"');
		document.write ('width="'+intWidth+'"');
		document.write ('height="'+intHeight+'"');
		document.write ('type="application/x-shockwave-flash">');
	}
	if (arParams) {
		for (x in arParams) {
			keyvalue = arParams[x].split(":",2);
			document.write('<param name="' +keyvalue[0]+ '" value="' + keyvalue[1] + '" />');
		}
	}
	document.write ('<param name="movie" value="' + strFile + '" />');
	if (strAltHTML) document.write(strAltHTML);
	document.write ('</object>');
}

function $(elem)
{
	return document.getElementById(elem);
}

function go(loc)
{
	document.location.href = loc;
}

function goBack()
{
	history.back();
}

function goHide(obj)
{
	obj.style.display = 'none';
}

function goFocus(obj)
{
	obj.focus();
}

function goShow(obj)
{
	obj.style.display = 'block';
}

function goDisable(obj)
{
	obj.disabled = true;
}

function goEnable(obj)
{
	obj.disabled = false;
}

function goClearField(obj, text)
{
	if (obj.value == text) obj.value = '';
}

function goFillField(obj, text)
{
	if (obj.value == '') obj.value = text;
}

function goPopup(where)
{
	window.open(where);
}

function goPopupMinimal(loc,w,h)
{
	var leftVal = (screen.width / 2) - (w/2);
	var topVal = (screen.height / 2) - (h/2);
	window.open (loc, 'new_window', 'left=' +leftVal+ ',top=' + topVal + ',toolbar=no,width=' + w + ',height=' + h + ',status=no,resizable=yes,menubar=no,location=no,scrollbars=yes');
}

function getMousePosition(e)
{
	var posx = 0;
	var posy = 0;
	
	if (!e) var e = window.event;
	if (e.pageX || e.pageY) {
		posx = e.pageX;
		posy = e.pageY;
	} else if (e.clientX || e.clientY) {
		posx = e.clientX + document.body.scrollLeft	+ document.documentElement.scrollLeft;
		posy = e.clientY + document.body.scrollTop	+ document.documentElement.scrollTop;
	}

	var coordinates=new Object();
	coordinates.x=posx;
	coordinates.y=posy;

	return coordinates;
}