audio not playing in a webPopup

I don’t know if it is the best place for such a question but here it is:

When I open a webPopup on a HTML5 game including sounds, those are not played on my phone. But they are in a web browser.

Maybe there is something I don’t get, an obvious technical point I ignore, but nothing in the doc describe how audio should behave in a web popup.

So, is it normal? What should I do to have the audio play in my app?

FYI: I checked, phone is not muted, volume is okay, sound files are okay on the server.

It’s a restriction in mobile Safari. Apple don’t allow audio files to start automatically - in case you’re streaming off a server and potentially running up a data download charge although the same restriction applied for resources in the app bundle.

As far as I know the only way round it is to have some sort of user interaction to start audio playing e.g. pressing a button.

Hello spjnowak, and thanks for your answer.

The game has multiple sounds triggered by events, and the player has to tap on screen to start playing (it’s not an issue with a sound played as soon as the webview opens). But sounds still do not play. It is not critical yet, I will investigate following your leads. 

Thanks again

It’s a restriction in mobile Safari. Apple don’t allow audio files to start automatically - in case you’re streaming off a server and potentially running up a data download charge although the same restriction applied for resources in the app bundle.

As far as I know the only way round it is to have some sort of user interaction to start audio playing e.g. pressing a button.

Hello spjnowak, and thanks for your answer.

The game has multiple sounds triggered by events, and the player has to tap on screen to start playing (it’s not an issue with a sound played as soon as the webview opens). But sounds still do not play. It is not critical yet, I will investigate following your leads. 

Thanks again