[osflash] Javascript integration with theAdobeJavaScriptFlashGateway
Cosmin Cimpoi
cosmin.cimpoi at monogroup.com
Thu Oct 19 05:07:53 EDT 2006
Yes.
The reason it's an unique id is that if you open the same page twice the id s differ. If the id is hardcoded (so all instances listen on the same lc name) only one of the 2 swf s will receive the messages.
cosmin
----- Original Message -----
From: Alias™
To: Open Source Flash Mailing List
Sent: Wednesday, October 18, 2006 4:31 PM
Subject: Re: [osflash] Javascript integration with theAdobeJavaScriptFlashGateway
So what if I just figured out a unique ID and hardcoded it into the swf and the page? Would that work?
Cheers,
Alias
On 18/10/06, Cosmin Cimpoi <cosmin.cimpoi at monogroup.com> wrote:
Hi.
In order to call a method in that swf you need to know the name of the local connection it is listening to:
var uid = new Date().getTime();
The thing is that you (or they) need to pass it from html to that swf. Or to get it into javascript from that swf. Either way the js and swf need to agree on the same id. Some security issues realted to the diference of the originating domain of the swf could pop up so a AllowDomain instruction in that swf might be necessary.
cosmin
----- Original Message ----- From: Alias™
To: Open Source Flash Mailing List
Sent: Friday, October 13, 2006 5:06 PM
Subject: [osflash] Javascript integration with the AdobeJavaScriptFlashGateway
Hi guys,
Right now I'm using the adobe JavaScriptFlashGateway to communicate between flash and javascript.
However, I have a problem. I need to be able to communicate with a swf served by a third party, which is embedded via their own javascript, which I can't change.
So - is it possible to use the JavaScriptFlashGateway.js WITHOUT knowing the name/DOM location of the swf that I want to send it to?
Could I just set up something in the swf to identify it to the JavaScriptFlashGateway js?
Anyone done much of this before?
Thanks in advance,
Alias
--------------------------------------------------------------------------
_______________________________________________
osflash mailing list
osflash at osflash.org
http://osflash.org/mailman/listinfo/osflash_osflash.org
_______________________________________________
osflash mailing list
osflash at osflash.org
http://osflash.org/mailman/listinfo/osflash_osflash.org
------------------------------------------------------------------------------
_______________________________________________
osflash mailing list
osflash at osflash.org
http://osflash.org/mailman/listinfo/osflash_osflash.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://osflash.org/pipermail/osflash_osflash.org/attachments/20061019/08bdfb93/attachment-0001.htm
More information about the osflash
mailing list