# Help with menu, adding url

**URL:** <https://forum.kirupa.com/t/help-with-menu-adding-url/221108>\
**Category:** flash\
**Created:** [April 1, 2007, 3:15pm UTC](https://forum.kirupa.com/t/help-with-menu-adding-url/221108 "2007-04-01T15:15:05Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![sushi](https://avatars.discourse-cdn.com/v4/letter/s/50afbb/32.png) [@sushi](https://forum.kirupa.com/u/sushi)\
**Post date:** [April 1, 2007, 3:15pm UTC](https://forum.kirupa.com/t/help-with-menu-adding-url/221108/1 "2007-04-01T15:15:05Z")

</div>

I have a movie that plays inside of my stage for the menu. I have made many FLASH projects and websites, but this is the first time I attempted a dynamic menu instead of making each button individually. Everything works, mouseover plays the animation, and rollout works great as well. I even fixed the ONRELEASE so it stops on a specific frame indicating it had been clicked.

Where I am running into a problem is actually getting the menu to work and go to 6 different URLs. My first attempt using the “IF” command would launch 6 pages, one for each button, even if I only clicked one item. I realize I could easily fix this by going back and doing it the OLD way, but I really want to learn this actionscript stuff. Right now, no matter what I click, it only takes me to 1 page, even though I have all 6 programmed.

Button 1 is a separate button from the rest and it works great. Here is my actioscript for the remaining 2-6. The buttons “work” but when I press button 2, it takes me to what I programmed for 3 and the rest all just go to where I have button 2 programmed for.

You can see it [HERE](http://noobs.nuclearfallout.net//themes/CSS/images/noobs3.swf)

Could someone tell me what I’m doing wrong?

\*\*on (rollOver) {  
if (\_root.link != num) {  
gotoAndPlay(2);  
}  
// end if  
}  
on (releaseOutside, rollOut) {  
if (\_root.link != num) {  
gotoAndPlay(11);  
}  
// end if  
}  
on (release) {  
if (\_root.link != num) {  
\_parent[“but”+\_root.link].gotoAndPlay(“s2”);  
}  
\_root.link = num;  
if (\_root.link != 2) {  
getURL(“[http://google.com](http://google.com)”);  
} else if (\_root.link != 3) {  
getURL(“[http://cklivin.com](http://cklivin.com)”);  
} else if (\_root.link != 4) {  
getURL(“[http://ebay.com](http://ebay.com)”);  
} else if (\_root.link != 5) {  
getURL(“[http://kgw.com](http://kgw.com)”);  
} else if (\_root.link != 6) {  
getURL(“[http://cklivin.com/a.gif](http://cklivin.com/a.gif)”);  
}  
// end if  
}

\*\*
