Is it possible to auto close a Flash banner after it's done playing in a browser?
Can it be done through javascript? Or should it be configured in the flash file itself?
Is it possible to auto close a Flash banner after it's done playing in a browser?
Can it be done through javascript? Or should it be configured in the flash file itself?
What do you mean by "close" do you intend to collapse the space as well or just make it hidden? For the second the easy way is to end on an empty transparent frame. For the first you'd probably need javascript to remove it from the DOM.
As I understand it you want to remove the object/embed-stuff from the DOM-tree when it reaches the end of it´s timeline.
With this in mind I would say it´s possible. Not being a flash guru, but the flash should be able to call a javascript function that removes the appropriate DOM-element.
you could use ExternalInterface to call javascript to remove the object from your actionscript.
in your flash:
import flash.external.ExternalInterface;
ExternalInterface.call("removemovie");
in javascript:
function removemovie(){
//do stuff here to remove movie
}
Josh
you can add a action script to flash , that when the flash finish to play he call to javascript function that you wrote. in this function you hidden the element.