PDA

View Full Version : Drunken



Drunken
August 12th, 2003, 05:19 PM
Heya!

How can I close an Interstitial ?

I have this but doesn't work well:
on (release)
{

getURL("", _level0);
getURL(" javascript :this.close();");
}

thks!=)

lostinbeta
August 12th, 2003, 05:21 PM
Huh????

I don't get what you are trying to do.

thoriphes
August 12th, 2003, 05:21 PM
are you testing this from within flash? because technically flash isn't a browser so it won't close.

try publishing it then test it. I just did and it works fine.

Drunken
August 12th, 2003, 05:22 PM
see this: http://www.nunosantos.net.tc/golo/Golo!.htm

See the red coin ? I want that when user click on button this animation close

thks

lostinbeta
August 12th, 2003, 05:25 PM
You can ...

A) gotoAndStop at a blank frame in the movie

or

B) Use Javascript to hide a DIV tag that houses your movie


if you aren't up to date on Javascript then your easiest and best bet would be to use on(release){
gotoAndStop(emptyFrameNumber);
}

Where emptyFrameNumber is the frame number of the empty frame you have set aside.

Drunken
August 12th, 2003, 05:34 PM
if a put a emptyFrame the site beside will be inacessible because the swf still there.

:(

lostinbeta
August 12th, 2003, 05:41 PM
If you look at the movie in the link you provided the movie contains a transparent background (you can set this in the HTML tab of the Publish Settings). With a transparent background, if you go to an empty frame it will act as though no movie was there.

Although, if your viewer has the NEWEST (and I mean newest) plugin, this should work on most browsers in a Mac or PC environment, otherwise it will just work in IE for Windows.


Usually these things use Javascript to hide/show a div tag containing the data, I personally don't think this would be too hard to pull off, but I don't have the time to try it out either.


Question though... why would you want to make one of these things? They are more annoying than those infamous retarded pop-up ads :m: Just wondering...

Drunken
August 12th, 2003, 05:46 PM
Yah ... i agree but that is the costumer wants. Here in my country is very usually use this. You can I for example at www.tmn.pt that is the biggest phone operator on Portugal :P

lostinbeta
August 12th, 2003, 05:52 PM
That tmn site... They go to a blank frame in the movie.

If you right click in a blank area and choose "select all" you can see the big square get highlighted of your movie. When you set a movie to have a transparent background, the movie becomes selectable like an image.

Drunken
August 12th, 2003, 06:03 PM
I think you wrong because on tmn site the swf is closed. I am trying to do it with blankframe, but doesn't work, for example a link that is beside the swf is inacessible :(

Drunken
August 13th, 2003, 06:23 AM
:thumb: I have found a solution!

With javascript, by put a function on html page, like this:

<SCRIPT language=JavaScript>

<SCRIPT language=JavaScript> function fechar(){ var timeout=0; //Desparece automaticamente setTimeout("document.getElementById('flash').style.display='no ne';", timeout * 1000); }
</script>


and in flash movie put this:


on (release) {
getURL("javascript:fechar();");
}

xauz