/*
DETECT A FEW THINGS
-------------------
hasProductInstall:		Version check for the Flash Player that has the ability to start Player Product Install (6.0r65).
hasReqestedVersion:		Version check based upon the values defined in globals.
*/
var hasProductInstall = DetectFlashVer(6, 0, 65);
var hasReqestedVersion = DetectFlashVer(requiredMajorVersion, requiredMinorVersion, requiredRevision);
/*
Check to see if a player with Flash Product Install is available and the version does not meet the requirements for playback.
*/
if (hasProductInstall && !hasReqestedVersion) {
	/*
	LOCATION VISITED AFTER INSTALLATION IS COMPLETE IF INSTALLATION IS REQUIRED
	---------------------------------------------------------------------------
	MMdoctitle is the stored document.title value used by the installation process to close the window that started the process.
	This is necessary in order to close browser windows that are still utilizing the older version of the player after installation has completed.
	[!] DO NOT MODIFY THE FOLLOWING FOUR LINES [!]
	*/
	var MMPlayerType = (isIE == true) ? "ActiveX" : "PlugIn";
	var MMredirectURL = window.location;
	document.title = document.title.slice(0, 47) + " - Flash Player Installation";
	var MMdoctitle = document.title;
	//
	AC_FL_RunContent(
		"src", detect_src,
		"FlashVars", "MMredirectURL="+MMredirectURL+"&MMplayerType="+MMPlayerType+"&MMdoctitle="+MMdoctitle+"",
		"id", detect_id,
		"name", detect_name,
		"width", detect_embedwidth,
		"height", detect_embedheight,
		"base", detect_base,
		"wmode", detect_wmode,
		"quality", "high",
		"align", "middle",
		"allowScriptAccess", "sameDomain",
		"type", "application/x-shockwave-flash",
		"pluginspage", "http://www.adobe.com/go/getflashplayer"
	);
	/*
	Resize the flash container div.
	*/
	jsResizeFlash({nWidth:detect_width, nHeight:detect_height});
} else if (hasReqestedVersion) {
	/*
	If we've detected an acceptable version embed the Flash Content SWF when all tests are passed.
	*/
	AC_FL_RunContent(
			"src", content_src,
			"FlashVars", content_FlashVars,
			"id", content_id,
			"name", content_name,
			"width", content_embedwidth,
			"height", content_embedheight,
			"base", content_base,
			"wmode", content_wmode,
			"allowScriptAccess", content_allowScriptAccess,
			"quality", "high",
			"align", "middle",
			"type", "application/x-shockwave-flash",
			"codebase", "http://fpdownload.macromedia.com/get/flashplayer/current/swflash.cab",
			"pluginspage", "http://www.adobe.com/go/getflashplayer"
	);
	/*
	Resize the flash container div.
	*/
	jsResizeFlash({nWidth:content_width, nHeight:content_height});
} else {
	/*
	Flash is too old or we can't detect the plugin, so insert the non-flash content.
	*/
	var alternateContent = '<font color=\'0xFFFFFF\'><BR><BR>This content requires the Adobe Flash Player.<BR><BR>'
	+ '<a href=http://www.adobe.com/go/getflash/>http://www.adobe.com/go/getflash/</a></font>';
	document.write(alternateContent);
}

// check for IE on Mac
// added by DB
var sUserAgent = navigator.userAgent.toLowerCase();
if (sUserAgent.indexOf("mac") != -1 && sUserAgent.indexOf("msie") != -1)
	document.write("<p>We have detected that you are running Internet Explorer on a Mac</p>"
				+ "<p>This browser is no longer supported by Microsoft and Marcomedia which means the latest Flash player will not function correctly.</p>"
				+ "<p>We suggest that you download and install the Mozilla Firefox browser. This is free and can be downloaded from the following link.</p>"
				+ "<p><a href=\"http://www.mozilla.com/firefox/\">- Download Mozilla Firefox</a></p>"
				+ "<p>We apologise for the inconvenience.</p>"
				+ "<p>Thanks for visiting the Barry Salzman site.</p>");
