if (typeof com == "undefined") var com = new Object();
if (typeof com.deconcept == "undefined") com.deconcept = new Object();
if (typeof com.deconcept.util == "undefined") com.deconcept.util = new Object();
if (typeof com.deconcept.FlashObjectUtil == "undefined") com.deconcept.FlashObjectUtil = new Object();
com.deconcept.FlashObject = function (swf, id, w, h, ver, c, useExpressInstall, quality, xiRedirectUrl, redirectUrl, detectKey) {
if (!document.createElement || !document.getElementById) return;
this.DETECT_KEY = detectKey ? detectKey : 'detectflash';
this.skipDetect = com.deconcept.util.getRequestParameter(this.DETECT_KEY);
this.params = new Object();
this.variables = new Object();
this.attributes = new Array();
this.useExpressInstall = useExpressInstall;
if (swf) this.setAttribute('swf', swf);
if (id) this.setAttribute('id', id);
if (w) this.setAttribute('width', w);
if (h) this.setAttribute('height', h);
if (ver) this.setAttribute('version', new com.deconcept.PlayerVersion(ver.toString().split(".")));
this.installedVer = com.deconcept.FlashObjectUtil.getPlayerVersion(this.getAttribute('version'), useExpressInstall);
if (c) this.addParam('bgcolor', c);
var q = quality ? quality : 'high';
this.addParam('quality', q);
var xir = (xiRedirectUrl) ? xiRedirectUrl : window.location;
this.setAttribute('xiRedirectUrl', xir);
this.setAttribute('redirectUrl', '');
if (redirectUrl) this.setAttribute('redirectUrl', redirectUrl);
if (c = 'transparent') {
this.addParam('wmode', c);
}
}
com.deconcept.FlashObject.prototype = {
setAttribute: function (name, value) {
this.attributes[name] = value;
},
getAttribute: function (name) {
return this.attributes[name];
},
addParam: function (name, value) {
this.params[name] = value;
},
getParams: function () {
return this.params;
},
addVariable: function (name, value) {
this.variables[name] = value;
},
getVariable: function (name) {
return this.variables[name];
},
getVariables: function () {
return this.variables;
},
createParamTag: function (n, v) {
var p = document.createElement('param');
p.setAttribute('name', n);
p.setAttribute('value', v);
return p;
},
getVariablePairs: function () {
var variablePairs = new Array();
var key;
var variables = this.getVariables();
for (key in variables) {
variablePairs.push(key + "=" + variables[key]);
}
return variablePairs;
},
getFlashHTML: function () {
var flashNode = "";
if (navigator.plugins && navigator.mimeTypes && navigator.mimeTypes.length) { // netscape plugin architecture
if (this.getAttribute("doExpressInstall")) this.addVariable("MMplayerType", "PlugIn");
flashNode = '