// JavaScript Document created 4/13/06 by JohnC. for eClg
//This function pulls both the URL and SWF file name so relative links will still work
function CreateCode(URL,SWF,width,height)
{
  //This is the object string that we want.  All variables are passed in from the visual editor.
 
 var objectCode = "<OBJECT codeBase=http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0 height='"+height+"' width='"+width+"' classid=clsid:D27CDB6E-AE6D-11cf-96B8-444553540000><PARAM NAME='_cx' VALUE='4763'><PARAM NAME='_cy' VALUE='6879'><PARAM NAME='FlashVars' VALUE=''><PARAM NAME='Movie' VALUE='"+URL+SWF+"'><PARAM NAME='Src' VALUE='"+URL+SWF+"'><PARAM NAME='WMode' VALUE='Window'><PARAM NAME='Play' VALUE='-1'><PARAM NAME='Loop' VALUE='-1'><PARAM NAME='Quality' VALUE='High'><PARAM NAME='SAlign' VALUE=''><PARAM NAME='Menu' VALUE='-1'><PARAM NAME='Base' VALUE='"+URL+"'><PARAM NAME='AllowScriptAccess' VALUE='always'><PARAM NAME='Scale' VALUE='ShowAll'><PARAM NAME='DeviceFont' VALUE='0'><PARAM NAME='EmbedMovie' VALUE='0'><PARAM NAME='BGColor' VALUE=''><PARAM NAME='SWRemote' VALUE=''><PARAM NAME='MovieData' VALUE=''><PARAM NAME='SeamlessTabbing' VALUE='1'><PARAM NAME='Profile' VALUE='0'><PARAM NAME='ProfileAddress' VALUE=''><PARAM NAME='ProfilePort' VALUE='0'><embed src='"+URL+SWF+"' quality='high' pluginspage='http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash' type='application/x-shockwave-flash' width='"+width+"' height='"+height+"' BASE='"+URL+"'>  </OBJECT>";
		document.write(objectCode);
}

     