-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
42 lines (40 loc) · 1.28 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
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Video Streaming</title>
</head>
<body>
<h1>Video Streaming</h1>
<div id="player"></div>
<script type="text/javascript"
src="https://cdn.jsdelivr.net/npm/clappr@latest/dist/clappr.min.js"></script>
<script type="text/javascript" src="/assets/js/subtitles.js"></script>
<script>
new Clappr.Player({
source: '/storage/{{.Cdn}}/posts/{{.Post}}/{{.Video}}/index.m3u8',
watermark: "/img/logo.png",
position: 'top-right',
poster: '/img/poster.jpg',
parentId: '#player',
mediacontrol: {
seekbar: "#fe7e02",
buttons: "#fe7e02"
},
plugins: [ClapprSubtitle],
subtitle: {
src: '/storage/{{.Cdn}}/posts/{{.Post}}/{{.Video}}/subtitle.srt',
auto: true, // automatically loads subtitle
// backgroundColor : 'transparent',
// fontWeight : 'normal',
fontSize: '18px',
// color: 'yellow',
textShadow: '1px 1px #000',
},
});
</script>
</body>
</html>