How to load background music on the mobile page? I tried to use the embed tag, but the load was invalid.

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">

    <title> </title>
    </head>

<body>
<div class="displayNone">
            <embed src="./static/videos/297.mp4" autostart="true" loop="true" hidden="true" />
        </div>
</body>
</html>

can be used on a computer, but cannot be loaded on a mobile phone


Media playback on the mobile is considered to require user interaction before triggering content.
means that you need to guide the user to click on or touch the screen and then trigger the playback method of the tag based on the event.


try this API: AudioContext

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e95350-153a.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e95350-153a.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?