Product:
WonderPlugin Audio Player
Question:
I want to know how to write javascript to catch the event play and stop.
Answer:
You could use the following JavaScript code:
jQuery( "#wonderpluginaudio-1" ).on( "amazingaudioplayer.played" , function (event, data) { |
jQuery( "#wonderpluginaudio-1" ).on( "amazingaudioplayer.ended" , function (event, data) { |
jQuery( "#wonderpluginaudio-1" ).on( "amazingaudioplayer.paused" , function (event, data) { |
jQuery( "#wonderpluginaudio-1" ).on( "amazingaudioplayer.switched" , function (event, data) { |
Please change the number 1 in the above code to the ID of your player.