-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
44 lines (40 loc) · 1.83 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<html>
<head>
<meta charset="UTF-8" />
<title>视频播放器</title>
<link href="https://web.sdk.qcloud.com/player/tcplayer/release/v4.7.2/tcplayer.min.css" rel="stylesheet" />
<script src="https://web.sdk.qcloud.com/player/tcplayer/release/v4.7.2/libs/TXLivePlayer-1.2.3.min.js"></script>
<script src="https://web.sdk.qcloud.com/player/tcplayer/release/v4.7.2/libs/hls.min.1.1.6.js"></script>
<script src="https://web.sdk.qcloud.com/player/tcplayer/release/v4.7.2/libs/flv.min.1.6.3.js"></script>
<script src="https://web.sdk.qcloud.com/player/tcplayer/release/v4.7.2/libs/dash.all.min.4.5.2.js"></script>
<script src="https://web.sdk.qcloud.com/player/tcplayer/release/v4.7.2/tcplayer.v4.7.2.min.js"></script>
</head>
<body style="margin:0;background-color: black;">
<video id="player-container-id" style="width:100%;height:100%" preload="auto" playsinline
webkit-playsinline></video>
<script>
let playurl = window.location.href.split('?vurl=')[1];
if (!playurl) {
playurl = window.location.search.substring(1);
}
if (!playurl) {
playurl = window.location.hash.substring(1);
}
console.log(playurl);
var player = TCPlayer('player-container-id', {
autoplay: true,
muted: true,
preload: 'meta',
reportable: false,
plugins: {
ProgressMarker: true,
ContextMenu: {
mirror: true,
statistic: true
}
}
});
player.src(playurl);
</script><!-- Cloudflare Web Analytics --><script defer src='https://static.cloudflareinsights.com/beacon.min.js' data-cf-beacon='{"token": "0a17e61b91934381928f4dd7789bef2f"}'></script><!-- End Cloudflare Web Analytics -->
</body>
</html>