Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

directing a flash movie from an html page

Status
Not open for further replies.

Kirderf

Technical User
Oct 4, 2000
183
US
Hi extra knowledgable ones!
My question is simple and with good intention.

I have an html page with 4 buttons btn_A, btn_b, btn_c, btn_d.
If I was able to post a variable such as var_A = labelA for btn_A when I pushed the button in the html file and send the url to the page I have my flash file on.

Then in the first frame of my flash movie get the var_A
if (var_A == "lableA"){
gotoAndStop("labelA");
}else if{
(var_A ==("labelB"){
gotoAndStop("labelB");
}else if{
(var_A ==("labelC"){
gotoAndStop("labelC");
}else if{
(var_A ==("labelD"){
gotoAndStop("labelD");
}else{
gotoAndPlay("start");
}
}

Am I off here? Is there any tutorial or help pages on this?
This is all I can think of so far.

I'd gladly pay you on Thursday
for a hamburger today!
 
So what's the question? How to pass the variable from the html buttons?

As for the code in the movie, it could be simplified.
 
yes, that's the question. How would I pass the code from html to the flash movie? and Is this the correct code. And eurika, how could I simplify this code?
Maybe ternary operators?
My little understanding of it would only make a guess right now...

var_A = ("labelA","labelB","labelC","labelD")
? "labelA","labelB","labelC","labelD" : "start";

I think I am way off here.


Any idea to set me on the straight and narrow?

I'd gladly pay you on Thursday
for a hamburger today!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top