Skip to content

Instantly share code, notes, and snippets.

@jhollingworth
Created February 1, 2011 13:59
Show Gist options
  • Select an option

  • Save jhollingworth/805891 to your computer and use it in GitHub Desktop.

Select an option

Save jhollingworth/805891 to your computer and use it in GitHub Desktop.
//So I've got a flash video which has got a bit of text on it which I have converted to a button symbol.
//What I want it to do is call a javascript function when I click on the button. What i've got at the moment is:
on (press) {
import flash.external.ExternalInterface;
ExternalInterface.call("test");
trace("I've been pressed");
}
//When I run this in debug mode it does print "I've been pressed" to the output window so I'm assuming this is working. When I place this //on the page with the following js in the header however nothing happens...
<script language="javascript" type="text/javascript">
function test() {
alert("Hey");
}
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment