# Variables-newbie

**URL:** <https://forum.kirupa.com/t/variables-newbie/85657>\
**Category:** Uncategorized\
**Created:** [April 6, 2005, 12:42pm UTC](https://forum.kirupa.com/t/variables-newbie/85657 "2005-04-06T12:42:14Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ralleskalle](https://avatars.discourse-cdn.com/v4/letter/r/e9c0ed/32.png) [@ralleskalle](https://forum.kirupa.com/u/ralleskalle)\
**Post date:** [April 6, 2005, 12:42pm UTC](https://forum.kirupa.com/t/variables-newbie/85657/1 "2005-04-06T12:42:14Z")

</div>

I start the same movieclip with two different buttons (1 & 2), and they have  
variables:  
1: a = “1”  
2: a = “2”

in the last frame of a movieclip I have this script:

if (a= “1”) {  
getURL(“[http://student.umb.no/~dmunne/konserter/index.htm](http://student.umb.no/~dmunne/konserter/index.htm)”);  
}  
if (a= “2”) {  
getURL(“[http://student.umb.no/~dmunne/nederland/index.htm](http://student.umb.no/~dmunne/nederland/index.htm)”);  
}

I thought that now, when I press the first button, it plays the movieclip and then goes to the first URL, and when I press the second button it plays the movieclip (the same as button 1) and goes to the second URL.

Why does it make the browser open both URL’s when I test the movie?
