Here is the flash object I would like to embed:
Code:
<object classid="clsid:d2711cf-ac6d-11cf-96b8-444511cf000" 
              codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" 
              width="300" height="300" align="middle">
    <param name="allowScriptAccess" value="sameDomain" />
    <param name="movie" value="http://www.abc.com/loader.swf" />
    <param name="base" value="http://www.abc.com/" />
    <param name="flashvars" value='xml=<?php echo $encodeVars;?>' />
    <param name="loop" value="false" />
    <param name="menu" value="true" />
    <param name="quality" value="best" />
    <param name="wmode" value="transparent" />
    <param name="bgcolor" value="#ffffff" />
    <embed src="http://www.abc.com/loader.swf" base="http://www.abc.com/" 
               flashvars='xml=<?php echo $encodeVars;?>' 
               loop="false" menu="true" quality="best" wmode="transparent" 
               bgcolor="#ffffff" width="300" height="300" align="middle" 
               allowScriptAccess="sameDomain" type="application/x-shockwave-flash" 
               pluginspage="http://www.macromedia.com/go/getflashplayer"></embed>
</object>
Then I would like to embed the flash by using SWFObject. But for some reason it's not showing the swf movie.
Here is the code in the body by using SWFObject:
Code:
<div id="flashcontent">
This text is replaced by the Flash movie.
</div>
<script type="text/javascript">
// <![CDATA[
var so = new SWFObject("http://www.abc.com/loader.swf", "flashObj", "300", "300", "8", "#FFFFFF", true); 
so.addParam("allowScriptAccess", "sameDomain"); 
so.addParam("movie", "http://www.abc.com/loader.swf"); 
so.addParam("base", "http://www.abc.com/"); 
so.addParam('flashvars', 'xml=<?php echo $encodeVars;?>'); 
so.addParam("loop", "false"); 
so.addParam("wmode", "transparent"); 
so.addParam("quality", "best");
so.write("flashcontent");

// ]]>
</script>
At the moment it's displaying the replacement text, but not the swf movie. What am I doing wrong here? Is my flashvars doing wrong? Thanks!