0

I have made a simple flash button. I want it so that on click = myJSfunction()

I tried adding an on click to the div which holds the flash object but the function is never called. What is the correct way to do this?

Thanks in advance

0

2 Answers 2

1

You need to use ExternalInterface to push the flash button's click event out to your javascript function, I think it swallows all clicks otherwise.

http://www.adobe.com/livedocs/flash/9.0/ActionScriptLangRefV3/flash/external/ExternalInterface.html

Sign up to request clarification or add additional context in comments.

1 Comment

i know this is the correct way after reading around a bit, but whevenr I add the action to my single layer which has moving text the animation doesnt accur when viwed in browser and the function is not called
0

This is very similar to onMouseover a flash element?

Add the mouse listener to the flash <object> or <embed> element itself, instead of the <div>.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.