// Version check based upon the values entered above in "Globals"
var hasReqestedVersion = DetectFlashVer(requiredMajorVersion, requiredMinorVersion, requiredRevision);

// Check to see if the version meets the requirements for playback
if (hasReqestedVersion) {  // if we've detected an acceptable version
    var oeTags = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'
    + 'width="589" height="650"'
    + 'codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab">'
    + '<param name="movie" value="images/stories/advancedmedia/extras.swf?lang='+lang+'" /><param name="quality" value="high" /><param name="menu" value="false"><param name="wmode" value="window"><param name="bgcolor" value="#ffffff" />'
    + '<embed src="images/stories/advancedmedia/extras.swf?lang='+lang+'" quality="high" menu="false" bgcolor="#FFFFFF" '
    + 'width="589" height="650" aligh="left"'
    + 'play="true"'
    + 'loop="true"'
    + 'quality="high"'
    + 'allowScriptAccess="sameDomain"'
    + 'type="application/x-shockwave-flash"'
    + 'wmode="window"'
    + 'pluginspage="http://www.macromedia.com/go/getflashplayer">'
    + '<\/embed>'
    + '<\/object>';
    document.write(oeTags);   // embed the Flash Content SWF when all tests are passed
} else {  // flash is too old or we can't detect the plugin
    var alternateContent2 = 'Alternate HTML content should be placed here.'
  	+ 'This content requires the Macromedia Flash Player.'
   	+ '<a href=http://www.macromedia.com/go/getflash/>Get Flash</a>';
   	var alternateContent1 = '<IMG NAME="altern" SRC="images/stories/advancedmedia/products_pvc00.jpg" WIDTH="589" HEIGHT="640" BORDER="0" ALT="">';
    document.write(alternateContent1);  // insert non-flash content
}
