Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

New Member
Posts: 2
Registered: ‎09-27-2011
My Device: playbook
My Carrier: CTO

[URGENT] player flash controlled by javascript, crossdomain issue ?



i've a webwork app, wich use a flash player (flowplayer).

this player is controlled by javascript. Using the playbook browser everything works nice.

but in the webwork app it does'nt work, the player cannot be controlled by the javascript.


the player is on a remote server and it seems to mee that the javascript cannot access the player because of crossdomain issues.

strangely when i try to put the player in the built app it does'nt work too (path/player.swf instead of http:/remoteserver.com/player.swf).


i tried to use the access config in the config.xml file to allow the remote server but it does'nt work too.


how can i get the same behavior in the app than in the browser ?


any idea





Posts: 3,708
Registered: ‎10-16-2008
My Device: Z10
My Carrier: Rogers

Re: [URGENT] player flash controlled by javascript, crossdomain issue ?

[ Edited ]

Are you using the Flash ExternalInterface capability?


If so, I believe both the HTML file (which determines the origin of the page and JavaScript running in it) must be hosted on the same domain as the SWF file.


Embedding the SWF file or the HTML file that embeds it in your WebWorks BAR file gives flash problems trying to determine the origin of the SWF and the page which shuts down External Interface.


From what I remember from our testing, if you want to use ExternalInterface both the SWF and the HTML it is embedded in must be on the remote server.




I also believe that if you configure HTML5 AppCache you can make the remote swf and html page get loaded in once and then be served up locally through the AppCache functionality.  So it would be a single download and if you wanted to update them you would have to update the server side AppCache manifest.

Tim Neil
Director, Application Platform & Tools Product Management
Follow me on Twitter