function FDetect() {








	this.PARTNER_COS = ["amd",
        "appro",
        "cray",
        "dell",
        "egenera",
        "hp",
        "lenovo",
        "microsoft",
        "novell",
        "oracle",
        "pressroom",
        "rackable",
        "sun",
        "verari",
        "vmware",
        "msvirtualization",
        "redhat",
        "quadcore",
	"citrix",
	"msccs",
	"msft_amd_webinar",
	"dell_bi_webinar",
	"msft_hpc_webinar",
	"microsoft_manufacturing",
        "avs"];
        
	this.PARTNER_DEST = ["bpKey=AMD_Booth",
        "bpKey=Appro",
        "bpKey=Cray",
        "bpKey=Dell_Booth",
        "bpKey=Egenera",
        "bpKey=HP_Booth",
        "bpKey=Lenovo_Booth",
        "bpKey=Microsoft_Booth",
        "bpKey=Novell_Booth",
        "bpKey=Oracle_Booth",
        "bpKey=Press_Room_AMD",
        "bpKey=Rackable",
        "bpKey=Sun_Booth",
        "bpKey=Verari",
        "bpKey=VMWare_Booth",
        "bpKey=Webinar_Center&pfVid=6",
        "bpKey=Webinar_Center&pfVid=7",
        "bpKey=Webinar_Center&pfVid=8",
	"bpKey=Webinar_Center&pfVid=4",
	"bpKey=Webinar_Center&pfVid=5",
	"bpKey=Webinar_Center&pfVid=1",
	"bpKey=Webinar_Center&pfVid=2",
	"bpKey=Webinar_Center&pfVid=3",
	"bpKey=Webinar_Center&pfVid=0",
        "bpKey=AMD_Validated_Solutions"];
	
//        "bpKey=Blades_Webinar_Resources&pfVid=3",
	this.checkFlash = checkFlash;
	this.writeFlashContent = writeFlashContent;
	this.translateCo = translateCo;
}

function checkFlash(requiredMajorVersion, requiredMinorVersion, requiredRevision) {
	// 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) {
		return (true);
	} else {  // flash is too old or we can't detect the plugin
		return (false);
	}
}

function writeFlashContent(swfName,width,height,flashVars,bkg) {
	// embed the Flash Content SWF when all tests are passed
	document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" width="' + width + '" height="' + height + '" id="' + swfName + '" align="middle">');
	document.write('<param name="allowScriptAccess" value="always" />');
	document.write('<param name="movie" value="' + swfName + '.swf" />');
	document.write('<param name="FlashVars" value="' + flashVars + '" />');
	document.write('<param name="quality" value="high" />');
	document.write('<param name="bgcolor" value="' + ((bkg != null) ? bkg : '#000000') + '" />');
	document.write('<embed src="'  + swfName + '.swf" quality="high" bgcolor="' + ((bkg != null) ? bkg : '#000000') + '" width="' + width + '" height="' + height + '" name="' + swfName + '" FlashVars="' + flashVars + '" align="middle" allowScriptAccess="always" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');
	document.write('</object>');
}

/**
 * @param co is the company name
 */
function translateCo(co) {
	for (var i=0;i<this.PARTNER_COS.length;i++) {
		if (co == this.PARTNER_COS[i]) {
			return(this.PARTNER_DEST[i]);
		}
	}
	return (null);
}
