몇 가지 도움이 필요합니다. 비디오 재생 목록을 만들려고하는데 2 html 파일 (index.html 및 video.html)을 만듭니다. video.html에서 팝업으로 비디오를 재생하려고하지만, 팝업을 닫거나 도처에 클릭하면 바로 index.html로 돌아갑니다. 하지만 index.html에서 video.html을 링크합니다. video.html을 닫지 않고 팝업을 닫는 방법. 내가 사용하는 구문에 의해 팝업을 닫을 수 있지만 문제는 어디에서나 클릭하면 video.html도 닫히고 index.html로 돌아갑니다. 여기 내 한 video.html 파일입니다전체 페이지를 닫지 않고 팝업을 닫는 방법
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="jquery.mobile-1.2.1.min.css"/>
<script src="jquery-1.8.3.min.js"></script>
<script src="jquery.mobile-1.2.1.min.js"></script>
\t <title></title>
\t
<script>
var vid = document.getElementById("video_mute");
vid.muted = true;//mute video on window load
function enableMute() {
vid.muted = true;
}
function disableMute() {
vid.muted = false;
}
function checkMute() {
alert(vid.muted);
}
</script>
</head>
<body>
<div data-role="page" id="satu"> \t
<div data-role="header">
<h1>abjad</h1></div>
<div data-role="content">
\t \t <ul data-role="listview">
\t \t \t <li><a href="#a" data-rel="popup" data-transition="pop">huruf A</a></li>
\t \t \t <li><a href="#b" data-rel="popup" data-transition="pop">huruf b</a></li>
\t \t </ul>
\t </div>
\t <div data-role="footer">footer</div>
\t <div data-role="popup" data-position-to="window" id="a">
\t \t <video width="block" id="video_mute" controls>
\t \t \t <source src="abjad_a.mp4" type="video/mp4">
\t \t \t <button onclick="enableMute()" type="button">Mute sound</button>
\t \t \t <button onclick="disableMute()" type="button">Enable sound</button>
\t \t \t <button onclick="checkMute()" type="button">Check muted status</button><br>
\t \t \t </video>
\t \t \t
\t </div> \t
</div>
사용'데이터 취소 가능한 ='여기 참조 문서는 "거짓"http://demos.jquerymobile.com/1.4.5/popup/이 -을 확인 이 페이지의 'Dialog' 단락의 예. BTW, jQuery 및 JQM 버전을 최신 안정 버전으로 업데이트해야합니다. https://stackoverflow.com/a/44910517/4845566 – deblocker