You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Jonas Lundberg <my...@gmail.com> on 2006/06/20 19:12:03 UTC

Is it possible to pass parameters to Flash in Cocoon?

Hello,
I am trying to start a flash file through Cocoon. What happens is that
the flash player is loaded, but the file parameter (see below) is not
passed to the flash player, and thus nothing is shown in the browser.
HTML:

<object type="application/x-shockwave-flash" width="640" height="500"
                      wmode="transparent"
data="flvplayer.swf?file=video/test.flv">
     <param name="movie" value="flvplayer.swf?file=video/test.flv" />
     <param name="wmode" value="transparent" />
</object>

My sitemap attempt:
<map:match pattern="*.swf">
     <map:read src="flash/{1}.swf"
                      mime-type="application/x-shockwave-flash"/>
</map:match>

Do I need a dedicated flash reader component for this to work? Has
anyone tried this before?

Regards
Hans

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: Is it possible to pass parameters to Flash in Cocoon?

Posted by Bertrand Delacretaz <bd...@apache.org>.
On 6/20/06, Jonas Lundberg <my...@gmail.com> wrote:

> ...Do I need a dedicated flash reader component for this to work?...

A plain reader will work for the swf file, and you don't need the
mime-type parameter, the reader will figure it out. You might need
another reader for the flv file, with the correct mime-type as I don't
think the standard reader knows that one.

Passing parameters to flash is a bit more complicated, you need two
"versions" of them for the different browsers.

Here's a known good example from www.nouvo.ch, as you can see it uses
both <object> and <embed> tags, each with its own duplicated set of
parameters.

<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"
codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0"
width="570" height="470" id="nouvoscope-recorder" align="middle">
<param name="allowScriptAccess" value="sameDomain">
<param name="movie"
value="publication-static/www/swf/nouvoscope-recorder.v083.swf?flashServerUrl=rtmp://fms.flash.ch&amp;applicationPath=nouvoscope&amp;forumId=94-3&amp;inReplyTo=&amp;storagePath=2006/06/20/22">
<param name="quality" value="high">
<param name="bgcolor" value="#ffffff">

<embed src="publication-static/www/swf/nouvoscope-recorder.v083.swf?flashServerUrl=rtmp://fms.flash.ch&amp;applicationPath=nouvoscope&amp;forumId=94-3&amp;inReplyTo=&amp;storagePath=2006/06/20/22"
quality="high" bgcolor="#ffffff" width="570" height="470"
name="nouvoscope-recorder" align="middle"
allowScriptAccess="sameDomain" type="application/x-shockwave-flash"
pluginspage="http://www.macromedia.com/go/getflashplayer">
</embed>
</object>

There's nothing specific about doing this with Cocoon, as long as the
HTML is correct and the SWF file is served, you'll be fine.

HTH,
-Bertrand

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org