//the document.write calls must be in a separate js file (not an included cfm) for the activeX fix to work
var swfName = "index.swf";
var swfWidth = "100%";
var swfHeight = "100%";
var swfObjectTagID = "index";

//all supporting functions are contained in flashInclude.cfm
var hasRightVersion = DetectFlashVer(requiredMajorVersion, requiredMinorVersion, requiredRevision);
if(hasRightVersion) {	
	document.write("<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" align=\"middle\" id=\"" + swfObjectTagID + "\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0\" width=\"" + swfWidth + "\" height=\"" + swfHeight + "\">");
	document.write("<param name=\"movie\" value=\"" + swfName + "\">");
	document.write("<param name=\"allowScriptAccess\" value=\"sameDomain\" />");
	document.write("<param name=\"bgcolor\" value=\"330000\">");
	document.write("<param name=\"quality\" value=\"high\">");
	document.write("<param name=\"wmode\" value=\"opaque\">");
	document.write("<embed bgcolor=\"330000\" src=\"" + swfName + "\" quality=\"high\" align=\"middle\" allowScriptAccess=\"sameDomain\" pluginspage=\"http://www.macromedia.com/go/getflashplayer\" type=\"application/x-shockwave-flash\" width=\"" + swfWidth + "\" height=\"" + swfHeight + "\" wmode=\"opaque\"></embed>");
	document.write("</object>");
}else{
	//Code to download the Flash 9 plugin goes here
	document.write("<br><br>Download the latest version of the <a href=\"http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash&promoid=BONRN\" target=\"_blank\">Flash Plugin</a> to view this content.");
}
