Embedded Audio / Stop, Pause, Start

Hello world,

I am having a difficult time trying to stop/restart a 60sec MP3 file on a click action. I could use some help with this. I have 2 audio files I am working with:

#Player1
This is a simple embedded MP3 that triggers a very quick 0.5sec sound of ‘metal clanking’ on a click action. This is working fine.

javascript:void( $("#player1")[0].play() );

#player2
This is an MP3 that plays a 60sec audio file. When triggered the ‘countdown’ sound will play. It’s working in combination with #player1 perfectly fine. The problem: If a button is pressed ideally I want to trigger ‘player1’, and restart ‘player2’ from 0sec again.

I hope that is clear. I am not able to post the file, but I have included the JS line that triggers the audio files.

javascript:void( $("#player2")[0].play() );

You should be able to replace play() with load()
If that doesn’t work with immediate replay from beginning of file, you might need to put your original “play” line after the “load” line (with “Wait 50 ms” between.)

Thank you for the comment.

I have tried both. I am sure its something simple that I am not doing correctly. I have attached an RP file with just the stuff need to play or trigger the audio files. This is driving me nuts, so I would greatly appreciate your help. It would be easier with code at this point.

Axure File
Audio_Help.rp (1.4 MB)

@pixelelement, I tried downloading and opening your .rp file and it caused Axure to crash hard. i rebooted and same crash happened again when opening your file, so something got corrupted.

I can point you to these threads for help on multiple audios.

It’ll be great if Axure would ramp up Axure.cloud Project Folders to host Audio Files of a dedicated project.