// Major version of Flash required
var requiredMajorVersion = 9;
// Minor version of Flash required
var requiredMinorVersion = 0;
// Minor version of Flash required
var requiredRevision = 0;
					
var hasProductInstall = DetectFlashVer(6, 0, 65);

var hasReqestedVersion = DetectFlashVer(requiredMajorVersion, requiredMinorVersion, requiredRevision);

if ( hasProductInstall && !hasReqestedVersion ) {
	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", "/Public/Player/Homepage/playerProductInstall",
		"FlashVars", "MMredirectURL="+MMredirectURL+'&MMplayerType='+MMPlayerType+'&MMdoctitle='+MMdoctitle+"",
		"width", "550",
		"height", "300",
		"align", "middle",
		"id", "detectionExample",
		"quality", "high",
		"bgcolor", "#3A6EA5",
		"name", "detectionExample",
		"allowScriptAccess","always",
		"type", "application/x-shockwave-flash",
		"pluginspage", "http://www.adobe.com/go/getflashplayer"
	);
} else if (hasReqestedVersion) {

    var so = new SWFObject('/Public/Player/player1.swf','mpl1',swfWidth,swfHeight,'10');
    so.addParam('allowfullscreen','true');
    so.addParam('allowscriptaccess','always');
    so.addParam('wmode','transparent');
    
    so.addVariable('file','http://light.polar.cz/videa/'+srcVideo);
    so.addVariable('hd.file','http://light.polar.cz/videa/'+srcVideo);
    so.addVariable('type','lighttpd');
    so.addVariable('hd.state',false);
    so.addVariable('autostart',false);
    so.addVariable('stretching','uniform');
    so.addVariable('image',srcPreview);
    so.write(element);
    
} else { 
	var alternateContent = 'Alternate HTML content should be placed here.<BR>'
	+ 'This content requires the Adobe Flash Player. '
	+ '<a href=http://www.adobe.com/go/getflash/>Get Flash</a>';
	document.write(alternateContent);
}
