I'm making a page which requires different soundclips to be launched from different buttons (over 20 in all). A single player with a playlist is not an option - I need one button per row in a table, each one launching a different MP3.


I have a simple Flash player file (player_mp3_maxi.swf), easy enough to use, I just need to embed the code once for each button.

That many instances of the player on the page slows down the load time for the page and it creates an issue with overlapping sound...

If someone clicks a button and then clicks another button without first stopping or pausing the original soundclip, the two play simultaneously. Three pressed equals three clips playing at once... etc.

I have set up a very simple example at http://www.amtphoto.com/flash


Is there a way to do it so that if you push a second button it stops the first clip and then plays the second one?

I suspect this may be done with "onClick" (the way it is done with a similar Flash button called "Wimpy Button") or with "StopAllSound" but my coding skills are not what they should be and all of my attempts at this have failed.

Any help would be appreciated.

Thanks!