I have a Flash object on my site, which has this code:
this.ld = new LocalConnection();
this.ld.allowDomain("*");
ExternalInterface.call("alert", this.ld.domain);
It alerts my domain successfully开发者_开发知识库. However, what I want is to access the HTML DOM through this using LocalConnection and not ExternalInterface directly.
Any ideas?
ExternalInterface
is your best bet in accessing HTML DOM. LocalConnection
is for communication between different SWF files within the same page/browser.
The LocalConnection class lets you create a LocalConnection object that can invoke a method in another
LocalConnection
object, either within a singleSWF
file or between multipleSWF
files.
精彩评论