PDA

View Full Version : Sound buttons


ConcertFreaK
03-04-2004, 06:45 PM
Hellooo...

I was wondering if someone with incredible knowledge about the Flash world could help me out with my little problem. :d

I am trying to put buttons on my site that plays an mp3 music clip. I have made a play button for each clip (there are 6 in total) so that when you click on the button the clip plays (i did this in the edit button/library mode where the clip starts to play in the down state).

This is what it does now:
When you click on a song it plays but when you click on another song it starts to play too. They play at the same time.

What I want it to do:
When you click on a song it plays and then when you click on another song, the previous song stops and the new song you clicked on starts to play.

It's probably a really easy script but I have no experience in actionscripting. I'm hoping you can help.

binkyboo
03-04-2004, 10:01 PM
stopAllSounds();


The function will..........well it's self-explanatory. So on your button first stop all sounds and then play the desired clip using the code you have working. Hope this helps!!