+ 6

setTimeout not working 🤔

Please help me to solve this error 🙂 And why it's play when I touch on screen within 2 seconds https://code.sololearn.com/WjSlXvDi587A/?ref=app

17th May 2022, 11:53 AM
🌍🌎🌏AIM🌏🌎🌍
🌍🌎🌏AIM🌏🌎🌍 - avatar
10 ответов
+ 6
I think Browsers has stopped supporting the play of audios after page loads without interacting with the page and can only be initiated when it has registered a gesture 🤷🏻.
17th May 2022, 12:22 PM
฿₳฿ɎⱠØ₱ɆⱤ 🍼
฿₳฿ɎⱠØ₱ɆⱤ 🍼 - avatar
+ 4
for security reasons auto playing audios will not work on SOLOLEARN. It will only work if the user start the audio by his own hands. But if you still want to autoplay then you should trick the user. For example, trick the user so that he/she will force to touch the screen, from there you can start the audio like create an ad popup, a custom alert Box, or just by simply touching the screen one time. This way you can force them to start the audio. 👇👇👇👇 read this about blocking of auto play audio https://developer.mozilla.org/en-US/docs/Web/Media/Autoplay_guide
17th May 2022, 1:38 PM
NonStop CODING
NonStop CODING - avatar
+ 3
Amaani yeah but only in w3school
17th May 2022, 3:53 PM
🌍🌎🌏AIM🌏🌎🌍
🌍🌎🌏AIM🌏🌎🌍 - avatar
+ 2
I think it is Sololearn, I tried pasting the code into W3schools tryIt editor and it worked fine
17th May 2022, 1:11 PM
Amaani
Amaani - avatar
17th May 2022, 1:24 PM
Chigozie Anyaeji 🇳🇬
Chigozie Anyaeji 🇳🇬 - avatar
+ 2
Hmm only here on sololearn you cant do this. I tried this many times but here it is not supported due to some reason. this is because of older version of browser engion used by sololearn.
17th May 2022, 3:10 PM
Ayush Kumar
Ayush Kumar - avatar
+ 2
Cheque your browser version 🌍🌎🌏ᴀɪᴍ🌍🌎🌏 It's working for me
18th May 2022, 1:38 AM
Ayush Kumar
Ayush Kumar - avatar
+ 1
丹ⓨㄩک廾 not working in Chrome and opera 🤔
17th May 2022, 3:23 PM
🌍🌎🌏AIM🌏🌎🌍
🌍🌎🌏AIM🌏🌎🌍 - avatar
0
ㅤMr. N♡ ♡N€☆ ㅤㅤ music not working 🙁
17th May 2022, 3:54 PM
🌍🌎🌏AIM🌏🌎🌍
🌍🌎🌏AIM🌏🌎🌍 - avatar
- 1
I think you need write js code to "js"(you write js to html)
18th May 2022, 9:29 PM
жен
жен - avatar