    /////////////////////////////\\\\\\\\\\\\\\\\\\\\\\\\\\\\\   //   JavaScript code for Personal Trainer Animated Help   \\  //  Written by Kevin Stanek of Stanek Software Development  \\ //                         29 Jun 2006                        \\/////////////////////////////////\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\var animHelpFlashFile   = new Array();var animHelpX = -1;animHelpFlashFile[++animHelpX] = "inst_add_activities";animHelpFlashFile[++animHelpX] = "inst_adjust_score_weighting_assgn_perc";animHelpFlashFile[++animHelpX] = "inst_adjust_score_weighting_assgn_pnts";animHelpFlashFile[++animHelpX] = "inst_adjust_score_weighting_gbk_perc";animHelpFlashFile[++animHelpX] = "inst_adjust_score_weighting_gbk_pnts";animHelpFlashFile[++animHelpX] = "inst_assignments";animHelpFlashFile[++animHelpX] = "inst_create_assign";animHelpFlashFile[++animHelpX] = "inst_create_course_blackboard_cms";animHelpFlashFile[++animHelpX] = "inst_create_course_no_copy";animHelpFlashFile[++animHelpX] = "inst_create_course_webct_cms";animHelpFlashFile[++animHelpX] = "inst_establishing_acct";animHelpFlashFile[++animHelpX] = "inst_gradebook_perc";animHelpFlashFile[++animHelpX] = "inst_gradebook_pnts";animHelpFlashFile[++animHelpX] = "inst_import_assign";animHelpFlashFile[++animHelpX] = "inst_synch_scores_blackboard_cms";animHelpFlashFile[++animHelpX] = "inst_synch_scores_webct_cms";animHelpFlashFile[++animHelpX] = "stud_establishing_acct";animHelpFlashFile[++animHelpX] = "stud_gradebook_perc";animHelpFlashFile[++animHelpX] = "stud_gradebook_pnts";animHelpFlashFile[++animHelpX] = "stud_homework_perc";animHelpFlashFile[++animHelpX] = "stud_homework_pnts";// -----------------------------------------------// AnimHelp// -----------------------------------------------function AnimHelp(animHelpFlashFileName){	AnimHelp(animHelpFlashFileName, "")	;}function AnimHelp(animHelpFlashFileName, prefix){	// find the proper record in the database	var flashNum;	for (flashNum = 0; (flashNum < animHelpFlashFile.length) && animHelpFlashFile[flashNum] != animHelpFlashFileName; flashNum++)	{		// keep looking	}		if (flashNum >= animHelpFlashFile.length)	{		alert("Could not find the flash file.");	}	else	{		// set the optimal window dimensions		var availHt = screen.availHeight - 35;		var winHt = 585;		var winWd = 640;		if (winHt > availHt)		{			winWd = Math.round(winWd * availHt / winHt);			winHt = availHt;		}			// form features with which to open the window		var openFeatures = "resizable=yes,menubar=no,scrollbars=no,top=" + screen.availTop + ",left=" + screen.availLeft + ",screenX=0,screenY=0";		openFeatures = openFeatures + ",height=" + winHt;		openFeatures = openFeatures + ",width=" + winWd;		// open the window		var win = window.open("", flashNum, openFeatures, "");			// bring the window to the top		win.focus();			// fill the window with the appropriate content		if (AnimHelpCheckFlashPlugin())		{			AnimHelpDoFlash(win, animHelpFlashFile[flashNum], prefix);		}		else		{			AnimHelpDoSorry(win);		}	}}// -----------------------------------------------// AnimHelpDoFlash// -----------------------------------------------function AnimHelpDoFlash(win, animHelpFlashFile, prefix){	var context = this.location.href;
    context = context.substring(0, context.lastIndexOf("/") + 1);
    
    if (typeof(prefix) == 'undefined')     {        prefix = "";    }    	if ((top.fromCMS) && (animHelpFlashFile.indexOf("_cms") == -1))	{		animHelpFlashFile += "_cms";	}	if (self.location.href.indexOf("swmarketing") != -1)	{		win.location.replace(animHelpFlashFile + '_host.htm');	}	else	{		win.location.replace(context + prefix + 'help/4_0/anim_help/' + animHelpFlashFile + '_host.htm');	}}// -----------------------------------------------// AnimHelpDoSorry// -----------------------------------------------function AnimHelpDoSorry(win){	win.document.open();	win.document.writeln('<html>');	win.document.writeln('  <head>');	win.document.writeln('    <title>');	win.document.writeln('      Sorry');	win.document.writeln('    </title>');	win.document.writeln('  </head>');	win.document.writeln('  <body bgcolor=#FFFFFF>');	win.document.writeln('    Sorry, your browser needs flash player to display this page!');	win.document.writeln('  </body>');	win.document.writeln('</html>');	win.document.close();}// -----------------------------------------------// AnimHelpCheckFlashPlugin// -----------------------------------------------function AnimHelpCheckFlashPlugin(){	var ShockMode = 0;	// if Internet Explorer for Mac	if (navigator.appName.indexOf("Microsoft") != -1)	{		// no way to check -- have faith		ShockMode = 1;	}	// if Navigator recognizes the mime type	else if (navigator.mimeTypes &&			 navigator.mimeTypes["application/x-shockwave-flash"] &&			 navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin)	{		// if Navigator allows plugins and Flash plugin is installed		if (navigator.plugins &&			navigator.plugins["Shockwave Flash"])		{			// rock and roll			ShockMode = 1;		}	}	return ShockMode;	}// -----------------------------------------------// AnimHelpWriteHTML// -----------------------------------------------function AnimHelpWriteHTML(animHelpFlashFile){	document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="100%" height="100%" align="middle" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0">');	document.write('  <param name="movie" value="' + animHelpFlashFile + '.swf">');	document.write('  <param name="quality" value="best">');	document.write('  <param name="bgcolor" value="#3366FF">');	document.write('  <param name="allowScriptAccess" value="sameDomain">');	document.write('  <embed type="application/x-shockwave-flash" width="100%" height="100%" align="middle" src="' + animHelpFlashFile + '.swf" quality="best" bgcolor="#3366FF" allowscriptaccess="sameDomain" pluginspage="http://www.macromedia.com/go/getflashplayer">');	document.write('  </embed>');	document.write('</object>');}