var contentVersion = 6; // change me to test for major version of Flash Player
var plugin = (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"]) ? navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin : 0;
if (plugin) {
		var words = navigator.plugins["Shockwave Flash"].description.split(" ");
	    for (var i = 0; i < words.length; ++i)
	    {
		if (isNaN(parseInt(words[i])))
		continue;
		var pluginVersion = words[i]; 
	    }
	var flashCanPlay = pluginVersion >= contentVersion;
}
else if (navigator.userAgent && navigator.userAgent.indexOf("MSIE")>=0 
   && (navigator.appVersion.indexOf("Win") != -1)) {
	document.write('<scr' + 'ipt language=VBScript\> \n'); // hide this from IE4.5 Mac by splitting the tag
	document.write('on error resume next \n');
	document.write('flashCanPlay=(IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash." & contentVersion)))\n');
	document.write('</scr' + 'ipt\> \n');
}
if (flashCanPlay) {
	// write .swf file
	document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" width="920" height="600" id="whitecountess" align="middle">');
	document.write('<param name="allowScriptAccess" value="sameDomain" />');
	document.write('<param name="movie" value="whitecountess.swf" /><param name="quality" value="high" />');
	document.write('<param name="bgcolor" value="#000000" />');
	document.write('<embed src="whitecountess.swf" quality="high" bgcolor="#000000" width="920" height="600" name="whitecountess" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');
	document.write('</object>');
	
	function changestate(playStatus) {	}
	
} else {
	// write alternate image with href
	//document.write('<a href="#"><img src="mySWF.jpg" alt="" width="551" height="575" border="0"></a>');

	// write alternate text
	document.write('<p>To view this content, you will need Flash version 6 or higher. You can download the free Flash player <a href="http://www.macromedia.com/go/getflashplayer/" target="_blank" title="Download Flash player">here</a>.</p>');

	// or redirect the user, etc
	//self.location = "myURI.html";
}
