views:

23

answers:

1

Hi there,

I've been researching about Flex and it seems that it's possible to use JavaScript to interact with the Flash component. What I would like to know is if there are any security issues when doing this versus just building everything within the SWF?

Thanks

A: 

You have to explicitly define in your Flex code which Javascript functions to respond to.

Look at ExternalInterface.addCallback()

As for Security: there are mechanisms in place to keep things 'secure'.

For local content running in a browser, calls to the ExternalInterface.addCallback() method work only if the SWF file and the containing web page are in the local-trusted security sandbox.

For more info, read through the API

clownbaby