# Movie Clip Button woes...:/

**URL:** https://forum.kirupa.com/t/movie-clip-button-woes/10081
**Category:** flash
**Created:** [December 24, 2002, 1:02am UTC](https://forum.kirupa.com/t/movie-clip-button-woes/10081 "2002-12-24T01:02:07Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![LegaiAA](https://avatars.discourse-cdn.com/v4/letter/l/8797f3/32.png) [@LegaiAA](https://forum.kirupa.com/u/LegaiAA)
#### Post date: [December 24, 2002, 1:02am UTC](https://forum.kirupa.com/t/movie-clip-button-woes/10081/1 "2002-12-24T01:02:07Z")

</div>

Well I have been working on this little do-dad for about 2 days now and I can’t seem to get it right…

button.onRollOver = function() {  
\_root.button.gotoAndPlay(2);

```
_root.button.onPress = function () {
getURL("http://www.caribase.com", "_parent");

button.onRollOut = function() {
	_root.button.gotoAndPlay(16);

```

};  
};  
};

Basically when a user positions his mouse over a button, it will fade in, and when he moves the mouse off it, it fades out.

My probem is that when the user positions his mouse over the button, it fades in. But when they move their mouse off it, it stays faded in and doesn’t fade out.

How can I adjust this code so that it acually works with the button fading out.

Attached is my .fla file, the only button that I have setup is the “home” button, the others aren’t adjusted yet.

Hope someone can help me…

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [December 24, 2002, 4:49am UTC](https://forum.kirupa.com/t/movie-clip-button-woes/10081/2 "2002-12-24T04:49:04Z")

</div>

I took a look at your fla and all your other buttons seem to fade in and out just fine, the only one that had a problem was your home button which I fixed so it should be fading smoothly now.  
Here is your fixed file. =)

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [December 24, 2002, 4:54am UTC](https://forum.kirupa.com/t/movie-clip-button-woes/10081/3 "2002-12-24T04:54:06Z")

</div>

Thanks EG… 🙂

But I forgot to mention something…oops…

I had the setup like that before. If you move the mouse over the “Home” button once and click it, it doesn’t work.

If you move the mouse off it, then back on to it, then it works.

Basically what happens is that a user would have to move his mouse over all the buttons, before they are able to click them as a link.

And the other buttons aren’t setup yet, it’s just the “Home” button that I need to work. After I see the actionscript for it, I can setup the other buttons in the same manner.

Hope this sheds some more light on the problem at hand…

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [December 24, 2002, 5:27am UTC](https://forum.kirupa.com/t/movie-clip-button-woes/10081/4 "2002-12-24T05:27:56Z")

</div>

Ah ok I see what you’re saying and it seems that the onpress function you had wasn’t responding all of the time so what I did was split up your code. I left the rollover and rollout portion of the code on the timeline like how you had it, but I took the onpress portion and applied it directly to the buttons using the on release actions instead. I went ahead and fixed the first 3 buttons and they work a lot better. Just click on the button to select it and open your actions panel and you’ll see the actions I used. Hope that solves it, here is your fla. =)

BTW, make sure you delete the onpress actions from your orginal codes after you add in the new actions to the button. =)

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [December 24, 2002, 6:50am UTC](https://forum.kirupa.com/t/movie-clip-button-woes/10081/5 "2002-12-24T06:50:13Z")

</div>

coolzzzzzzzzzzzzzzzzz…

thanks for the help EG, I do appreciate it alot.

Works like a charm…

btw, wicked website…it ownz…

Happy Holidays \<:}

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [December 24, 2002, 7:38am UTC](https://forum.kirupa.com/t/movie-clip-button-woes/10081/6 "2002-12-24T07:38:40Z")

</div>

No problem, welcome to Kirupa by the way, I hope you’ll stick around. =)

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [December 25, 2002, 8:14am UTC](https://forum.kirupa.com/t/movie-clip-button-woes/10081/7 "2002-12-25T08:14:26Z")

</div>

```auto

on(release) {
	getURL("http://www.caribase.com/music.shtml", "_parent");
}

```

Might I ask what is the use of “\_parent” in this code?

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [December 25, 2002, 8:17am UTC](https://forum.kirupa.com/t/movie-clip-button-woes/10081/8 "2002-12-25T08:17:06Z")

</div>

I’m not sure, but I think it’s suppose to open the link in the current browser that the link is on instead of opening it in a new browser like “\_blank” does.

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [December 25, 2002, 8:49am UTC](https://forum.kirupa.com/t/movie-clip-button-woes/10081/9 "2002-12-25T08:49:31Z")

</div>

yeppers…

that’s correct.

\_parent = opens it in the same window

\_blank = opens it in a new window

\_self = opens up in same window

\_top = not too sure but this is used with frames
