Disable playing music on iPhone in silent mode

Hello guyz,

I’m writing here today about my problem according stop playing audio in silent mode on iPhone in a game built with cocos2dx-js. I’d developed a game for publishing in messenger with cocos2dx-js but it was rejected due to playing audio in silent mode on iPhone devices though the audio files are playing properly on pc browser and android devices.

I found a suggestion to use web audio api to solve the problem and got the SimpleAudioEngine.js class which includes WebAudioEngine which uses the api and added the class to my project to use that. I was needed to modify the class slightly to make that runnable. But I’m still facing the same problem. Audio files are still playing on iPhone or iPad devices even when they are on silent mode.

I want to get rid out of this and searched for a solution through the internet but I didn’t get enough sources. All of the suggestions found by the search is giving solution to play audio files in silent mode which is opposite to my problem. Please let me know if anyone can help me to get the problem fixed.

Thank you