Forum Moderators: open

Message Too Old, No Replies

html buttons to control flash banner

html, flash, buttons, pass, variables

         

stickygoblin

3:31 pm on Dec 3, 2004 (gmt 0)

10+ Year Member



hi

again i need a little instruction from the experts and i thought of you guys!

i understand the principle of passing variables to an swf but not to an swf embeded in an html.

i have a banner which needs to have a diofferent image in it for each page although its essently the same banner animation.

when a button is clicked to go to a new page i would like the animation to play and the page change once its completed ( i know how bad this sounds but honestly clients - you just can't get any good ones these days)

so i have my variable "going" in the flash movie which i want to set from the buttons which i think should be:

<a href="/my/movie/banner.swf?going=/my/page/new.html">

then in the movie i have:

if (going==/my/pages/new.html) {
gotoAndPlay(nextFrame);
}

which in turn should make the final animation run, at the end of which i have:

getURL(going);

ok thats it, not entirely sure this will work but someone will have done it and if not someone knows more about it than myself

antisipating madley

Doug

rocknbil

4:58 pm on Dec 3, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



First, did you try

if (going=='/my/pages/new.html') { ....?

Being a string literal you might have to quote it.

Second, put a dynamic text box (temporary) in your flash and in some frame before getURL set it's value to 'going' to verify it's getting the value you're passing. This will tell you if what you're getting in the web environment is the same as what you're getting in thr Flash test movie environment.