I'm wondering if there's a way to control the player through jquery / javascript events? I've put the mp3 player into a Bootstrap modal and want to stop the current player when the 'close' button is pressed.
No problem, thanks for getting back to me. And is there a way of stopping all players from playing by clicking a link? It looks like I have to specify a player to interact with it correct? i.e. there's no global 'stop' button right?
Hi,
I'm wondering if there's a way to control the player through jquery / javascript events? I've put the mp3 player into a Bootstrap modal and want to stop the current player when the 'close' button is pressed.
Many thanks,
Osu
Hi,
Sorry for the wait.
You can start the first audio player in the current page with this JS code
IRON.players[0].play();
If you have a second player in the same page you can use IRON.players[1].play();
And IRON.players[2].play(); for the third one. Etc.
Thanks,
Alexandre from the Sonaar.io Crew
Hi Alexandre,
No problem, thanks for getting back to me. And is there a way of stopping all players from playing by clicking a link? It looks like I have to specify a player to interact with it correct? i.e. there's no global 'stop' button right?
Thanks,
Osu
No.
No global stop is available
Thanks,
Alexandre from the Sonaar.io Crew
I see, and no way to loop through all players on the page and stop them one by one?
Probably that is doable by using some custom JS code but unfortunately, this is beyond the scope of our support Im afraid.
Thanks,
Max from the Sonaar.io Crew
ok, I appreciate that. Last question - is there any documentation for the player?
We dont have extensive documentation on the player beside how to install it.
Thanks,
Max from the Sonaar.io Crew