walius100
08-27-2009, 12:49 PM
Hello, here is my problem:
I have AS2 flash file, some kind like menu, and I'm using flash.external.ExternalInterface to call javascript functions on my site. I added this code to my AS layer:
stop();
import flash.external.ExternalInterface;
function one() {
ExternalInterface.call("one");
}
vienas.addEventListener("click", one);
button name is "vienas" and in my HTML I have JS function "one" this function simply loads some data in iframe tag.
all seems to be OK but it only works when I use button from flash components (the default white, rounded button)
AS doesn't calls JS when I use my own button (like text or simple box as button)
All I need is a custom button, which can call JS function.
It only works with button from flash components.
Maybe anyone have suggestions?
Thanks.
I have AS2 flash file, some kind like menu, and I'm using flash.external.ExternalInterface to call javascript functions on my site. I added this code to my AS layer:
stop();
import flash.external.ExternalInterface;
function one() {
ExternalInterface.call("one");
}
vienas.addEventListener("click", one);
button name is "vienas" and in my HTML I have JS function "one" this function simply loads some data in iframe tag.
all seems to be OK but it only works when I use button from flash components (the default white, rounded button)
AS doesn't calls JS when I use my own button (like text or simple box as button)
All I need is a custom button, which can call JS function.
It only works with button from flash components.
Maybe anyone have suggestions?
Thanks.