
// Universal event handler
// Please don't use "onload = functionName" etc
// use instead this "addEvent(window, 'load', functionName);"
function addEvent(obj, strEvent, objFunction)
{ 
	if (obj.addEventListener) { 
		obj.addEventListener(strEvent, objFunction, true); 
		return true; 
	}
	else if (obj.attachEvent) { 
		var returnValue = obj.attachEvent("on"+strEvent, objFunction); 
		return returnValue; 
	} 
	else return false; 
}

addEvent(window, "load", ResetFooterOnPageInit);

// be careful: this script erases the "FlashVars" content, 
// you can send vars in the file name after "?" like in asp
function startObjects()
{
	objects = document.getElementsByTagName("OBJECT");
	for (var i = 0; i < objects.length; i++)
	{
		if (objects[i].classid.toUpperCase() == "CLSID:D27CDB6E-AE6D-11CF-96B8-444553540000")
			objects[i].outerHTML = objects[i].outerHTML;
	}
}

/*if (navigator.appName == "Microsoft Internet Explorer") {
	addEvent(window, 'load', startObjects);
}*/


function fnPrintFlashAdv(sFileURL, nWidth, nHeight,id, sFVars) {
	if (window.ActiveXObject)
		document.write("<object type=\"application/x-shockwave-flash\" id=\"" + id + "\" width=\"" + nWidth + "\" height=\""+ nHeight + "\">");
	else
		document.write("<object FlashVars=\"" + sFVars + "\" type=\"application/x-shockwave-flash\" id=\"" + id + "\" width=\"" + nWidth + "\" height=\""+ nHeight + "\" data=\"" + sFileURL + "\">");
	document.write("<param name=\"movie\" value=\"" + sFileURL + "\">");
	document.write("<param name=\"quality\" value=\"high\">");
	document.write("<param name=\"wmode\" value=\"transparent\">");
	document.write("<param name=\"FlashVars\" value=\"" + sFVars + "\">");
	document.write("</object>");
}
