// JavaScript Document

function createFlashPlayer(player, w, h, id, file, wmode, altContent){

// Check to see if the version meets the requirements for playback -- 
	//hasReqestedVersion = true;
	if (hasReqestedVersion) {
		// if we've detected an acceptable version
		// embed the Flash Content SWF when all tests are passed
		
		AC_FL_RunContent(
				"src", player,
				"width", w,
				"height", h,
				"align", "center",
				"id", id,
				"quality", "high",
				"bgcolor", "ffffff",
				"name", "slideshow",
				"allowScriptAccess","sameDomain",
				"type", "application/x-shockwave-flash",
				'codebase', 'http://fpdownload.macromedia.com/get/flashplayer/current/swflash.cab',
				"pluginspage", "http://www.adobe.com/go/getflashplayer",
				"base", ".",
				"wmode", wmode,
				"FlashVars", file,
 "class", "video-embed"
	);

	
	} else {  // flash is too old or we can't detect the plugin
		var alternateContent = '<div class= class="vidNoFlash" style="width: '+w+'px; height: '+h+'px; margin: 0 auto; border: 1px solid #000000;" ><p style="height: 50px; margin: auto; padding: 40% 15px 0 15px;">You must enable flash to view the '+altContent+' video.</p></div>'
		document.write(alternateContent);  // insert non-flash content
	}
}



function createFlashPlayerHome(player, w, h, id, file, wmode, altContent){

// Check to see if the version meets the requirements for playback -- 
	//hasReqestedVersion = true;
	if (hasReqestedVersion) {
		// if we've detected an acceptable version
		// embed the Flash Content SWF when all tests are passed
		
		AC_FL_RunContent(
				"src", player,
				"width", w,
				"height", h,
				"align", "center",
				"id", "locator",
				"quality", "high",
				"bgcolor", "ffffff",
				"name", "locator",
				"allowScriptAccess","sameDomain",
				"type", "application/x-shockwave-flash",
				'codebase', 'http://fpdownload.macromedia.com/get/flashplayer/current/swflash.cab',
				"pluginspage", "http://www.adobe.com/go/getflashplayer",
				"base", ".",
				"wmode", wmode,
				"FlashVars", "IMAGE_PATH=/files/flash/images/&amp;VIDEO_PATH=/files/flash/videos/&amp;DATA_PATH=/files/flash/data/",
 "class", "video-embed"
	);

	
	} else {  // flash is too old or we can't detect the plugin
		var alternateContent = '<img src="/files/flash/images/home-page-default.png" alt="home page flash" />'
		document.write(alternateContent);  // insert non-flash content
	}
}
altContentFeatured = 'You must have flash to view this video.';
