I created an audio player dynamically with autoplay enabled. But it is working with desktop browser not in android browser. And progress
handler not dispatched.
If I enable the controls
attribute and click the play button it will dispatch the progress handler and playing the audio. Even I was tried to play by manually by calling the play()
method.
I want to play the audio once canplaythrough
handler triggered.
Audio on mobile devices often requires a user event (click / touch) in order to play, which seems to be what is happening in your case.
You can check out the SoundJS Mobile Safe Tutorial to learn more about the issue and a couple of ways to work around it.
Hope that helps.