var DEBUG=false;
// this is for fireclick to track research document use
function track(doc) {
	if ("undefined"!=(typeof parent.tracker)) {
		parent.tracker.location.href = "documents/" + doc + ".html";
		}
	return true;
	}


// write either a flash movie or a static image
// part of flash modularization code
// boolean, use flash?
// id of flash as string
// width of flash/image in pixels
// height of flash/image in pixels
// relative path to flash
// relative path to image
// alt text for image
function flashImageText(flashbool,flid,flwid,flht,flpath,imgpath,imgalt) {
	if (flashbool) {
		return flashText(flid,flwid,flht,flpath);
		}
	else {
		return imgText(flwid,flht,imgpath,imgalt);
		}
	}


// write a flash movie into the document if it's supported
// part of flash modularization code
// id (as string)
// width in pixels
// height in pixels
// relative path to swf file
// this is a separate function so you can specify different height/width for flash vs image if necessary
function flashText(flid,flwd,flht,flpath) {
	var flstr;
	flstr = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"' +
				'  codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" ' +
				' id="' + flid + '" width="' + flwd + '" height="' +flht+ '" align="">' +
				' <param name="movie" value="' + flpath + '"><param name="loop" value="true"><param name="menu" value="false">' +
				'<param name="quality" value="high"> <param name="bgcolor" value="#ffffff">  ' +
				' <embed src="' + flpath + '" loop="true" menu="false" quality="high" bgcolor="#ffffff"  ' + 
				' swLiveConnect="FALSE" width="' + flwd + '" height="' + flht + '" name="' + flid + '" align=""' +
				' type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer">' +
				' </embed>' + 
				' </object>';
	return flstr;
}
// write a static image (instead of a flash movie) into the dociment
// part of flash modularization code
// width in pixels
// height in pixels
// relative path
// alt text
// this is a separate function so you can specify different height/width for flash vs image if necessary
function imgText(imgwid,imght,imgpath,imgalt) {
	return('<img src="' + imgpath + '" width="' + imgwid + '" height="' + imght + '" alt="' + imgalt + '" />');
	}

// netscape plugin check
// part of flash modularization code
// no arguments
function plugCheck() {
				var words = navigator.plugins["Shockwave Flash"].description.split(" ");
				for (var i = 0; i < words.length; ++i)
				{
				if (isNaN(parseInt(words[i])))
				continue;
				var MM_PluginVersion = words[i]; 
				}
			var MM_FlashCanPlay = MM_PluginVersion >= MM_contentVersion;
			return MM_FlashCanPlay;
	}


// create flashcanplay w/ vbscript
// part of flash modularization code
// no arguments
function ieFlashwrite() {
	var flstr;
	flstr = '<scr' + 'ipt LANGUAGE=\"VBScript\"\> \n' + //FS hide this from IE4.5 Mac by splitting the tag
			'on error resume next \n' +
			'MM_FlashCanPlay = ( IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash." & MM_contentVersion)))\n' +
			'</scr' + 'ipt\> \n';
	return flstr;
}

if (DEBUG) {
	alert("done");
	}