﻿// <![CDATA[		
// ]]>

//	swf - The file path and name to your swf file.
//	id - The ID of your object or embed tag. The embed tag will also have this value set as it's name attribute for files that take advantage of swliveconnect.
//	width - The width of your Flash movie.
//	height - The height of your Flash movie.
//	version - The required player version for your Flash content. This can be a string in the format of 'majorVersion.minorVersion.revision'. An example would be: "6.0.65". //	Or you can just require the major version, such as "6".
//	background color - This is the hex value of the background color of your Flash movie.
//	Optional parameters are:

//	useExpressInstall - If you would like to upgrade users using the ExpressInstall feature, use 'true' for this value.
//	quality - The quality you wish your Flash movie to play at. If no quality is specified, the default is "high".
//	xiRedirectUrl - If you would like to redirect users who complete the ExpressInstall upgrade, you can specify an alternate URL here
//	redirectUrl - If you wish to redirect users who don't have the correct plug-in version, use this parameter and they will be redirected.
//	detectKey - This is the url variable name the SWFObject script will look for when bypassing the detection. Default is 'detectflash'.
//		Example: To bypass the Flash detection and simply write the Flash movie to the page, 
//		you could add ?detectflash=false to the url of the document containing the Flash movie.


// OPTIONAL
var useExpressInstall = "false";
var quality;
var xiRedirectUrl ="";
var redirectUrl = "";
var detectKey = "";
//	Create the swf object
var so = new SWFObject(swf, id, width, height, version, backgroundColor, null, quality, xiRedirectUrl, redirectUrl, detectKey);

//  OPTIONAL PARAMETERS FOR THE OBJECT/EMBED TAGS
//  see http://www.macromedia.com/cfusion/knowledgebase/index.cfm?id=tn_12701
so.addParam("quality", "high");
so.addParam("wmode", "Window");
//so.addParam("salign", "tl");
//so.addParam("BASE", ".");
so.addParam("allowScriptAccess", value="always");
so.addParam("scale", "noscale");
so.addParam("menu", "false");
so.addParam("loop", "true");
so.addParam("play", "true");
//so.addParam("SWLIVECONNECT", "false");

var charLength = swf.length;
var charLengthExt = swf.length-3
var fileExtension = swf.substring(charLengthExt, charLength);

if (fileExtension == "swf") so.write("promotionFlash");
