function createPlayer(videoPlaylist) {
      var s1 = new SWFObject('swf/mediaplayer-3.14.swf', 'mpl1', '380', '280', '7', '#000000');
          s1.addVariable('width',            '380');
          s1.addVariable('height',           '280');
          s1.addVariable('displayheight',    '280');
          s1.addVariable('displaywidth',     '420');
          s1.addVariable('file',              videoPlaylist);
          s1.addVariable('overstretch',      'true'); // expands to fit h or v  "false" -will stretch them to fit
          s1.addVariable('showdigits',       'true');
          s1.addVariable('autostart',        'false');
          s1.addVariable('shuffle',          'false');
          s1.addVariable('repeat',           'false');
          s1.addVariable('showicons',        'false');
		  s1.addVariable('showstop',         'true');
          s1.addVariable('enablejs',         'true');
          s1.addVariable('javascriptid',     'mpl1');
          s1.addVariable('usecaptions',      'true');
          s1.addVariable('backcolor',        '0xFFFFFF'); // face of buttons
          s1.addVariable('frontcolor',       '0x404040'); // button symbols & playlist text
          s1.addVariable('lightcolor',       '0x808080'); // highlighted playlist item
          s1.addVariable('screencolor',      '0x000000'); // screen background color
          s1.write('player');
    };
 
    function createRotator(slidePlaylist) {
//this is set at 10px square for the time being 

      var s2 = new SWFObject('swf/imagerotator-3.14.swf', 'rot1', '1', '1', '7', '#FFFFFF');
          s2.addVariable('width',            '1');
          s2.addVariable('height',           '1');
          s2.addVariable('file',              slidePlaylist);
          s2.addVariable('overstretch',      'true'); // expands to fit h or v  "false" -will stretch them to fit
          s2.addVariable('autostart',        'false');
          s2.addVariable('shuffle',          'false');
          s2.addVariable('repeat',           'false');
          s2.addVariable('rotatetime',       '999');
          s2.addVariable('showicons',        'false');
          s2.addVariable('shownavigation',   'false');
          s2.addVariable('transition',       'bgfade');
          s2.addVariable('enablejs',         'true');
          s2.addVariable('javascriptid',     'rot1');
          s2.addVariable('backcolor',        '0xCCEEFF'); // face of buttons
          s2.addVariable('frontcolor',       '0x404040'); // button symbols & playlist text
          s2.addVariable('lightcolor',       '0x808080'); // highlighted playlist item
          s2.addVariable('screencolor',      '0xFFFFFF'); // screen background color
          s2.write('rotator');

    };
	

	var list01='media\/videoPlaylist1.xml';
	var list02='media\/videoPlaylist2.xml';
	var list03='media\/videoPlaylist3.xml';
	var list04='media\/videoPlaylist4.xml';


     var tabArray01 = new Array(   
	{gtitle:'Eggdrop',gfile:'{file:list01}',gplayer:'mpl1'   },
	{gtitle:'Gazoo',gfile:'{file:list02}',gplayer:'mpl1'   },
	{gtitle:'Video3',gfile:'{file:list03}',gplayer:'mpl1'   },
	{gtitle:'Video4',gfile:'{file:list04}',gplayer:'mpl1'   },
	{gtitle:'not yet specified',gfile:'',gplayer:'mpl1',gurl:'',gdoFunc:''   } 
	 );
	 
/*function definitions:*/

  /*  function doit(jsid,mydiv){ //obsolete
       window.document.getElementById('rotator').innerHTML+=('jsid='+jsid+'mydiv= '+mydiv);
	   document.getElementById(mydiv).style.display="block";
	   document.getElementById('player').style.visibility="hidden";
	   delayedPlayPause(jsid);
	 }*/
	 
    /* function doit2(jsid,mydiv){ //obsolete
	   document.getElementById(mydiv).style.display="block";
	   thisMovie(jsid).sendEvent('playpause');
	 }*/
	 //shows player when it is hidden.
	 function hidePlayer(playerdivid){ if(playerdivid){(document.getElementById(playerdivid).style.visibility='hidden')};}
	 function showPlayer(playerdivid){ if(playerdivid){(document.getElementById(playerdivid).style.visibility='visible')}; }
	 
	 //shows hidden quiz or content-containing divs, hides the player if the player div id is specified, and pauses the player.
	 //If your content div will overlap the player, set hidePlayerID to 'player'. This keeps player from 
	 //showing through your content div.
	 function showDivAndPause(jsid,mydiv,hidePlayerID){ 
	     document.getElementById(mydiv).style.display="block";
		 hidePlayer(hidePlayerID);
		 pausePlayer(jsid);		 
		 }
		
	 function showDivAndPlay(jsid,mydiv,showPlayerID){
		 document.getElementById(mydiv).style.display="block";
		 showPlayer(showPlayerID);
		 delayedResumePlayer(jsid);
		 // alert('done');
		  }
	 
	  function ExternalJSTest(div2show){
			document.getElementById('rotator').innerHTML+=('fired off externalJSTest');
			showDiv(div2show);
			scrubTo('mpl1',25);
			closeItAndPlay('mpl1','rtDiv'); 
		 }
	 function hideIt(mydiv){  document.getElementById(mydiv).style.visibility='hidden';  }
	
	 function closeIt(mydiv){ document.getElementById(mydiv).style.display='none'; }
	  
	  function closeItAndPlay(jsid,mydiv){
		 closeIt(mydiv);
		 delayedResumePlayer(jsid); }
		 
	 function scrubTo(jsid,sec){
		 thisMovie(jsid).sendEvent('scrub',sec);
	
		}
	 function listTabs(tabDiv,tabArray){
		 var gtabBar = document.getElementById('tabBar');
		 gtabBar.innerHTML="";
		 for (var m=0; m< tabArray.length; m++){
			  var gplayer = tabArray[m].gplayer;
			  var gtitle = tabArray[m].gtitle;
			  var gfile = tabArray[m].gfile+"";
	       gtabBar.innerHTML+=("<li><a href=\'#\' onclick=\'loadAndStart(\""+ gplayer +"\","+gfile+");makeActive(this.id);\' class=\'tab tb_up_act\' id=\'tb_01_"+ m +"\' >"+gtitle+"</a></li>"); 
		 }
	 }
	 /*to write: chooseAQuiz
	 list tabs
	 */