forked from qjwlfx/qjwlfx.github.io
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
138 lines (125 loc) · 4.36 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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name=viewport
content="width=device-width,initial-scale=1,maximum-scale=1,minimum-scale=1,user-scalable=no,minimal-ui">
<meta name="referrer" content="no-referrer">
<style type="text/css">
html, body {
width: 100%;
height: 100%;
margin: auto;
overflow: hidden;
}
body {
display: flex;
}
#mse {
flex: auto;
}
</style>
<script type="text/javascript">
window.addEventListener('resize', function () {
document.getElementById('mse').style.height = window.innerHeight + 'px';
});
</script>
</head>
<body>
<div class="column">
<div id="mse"></div>
<div class="btn" style="height: 15px;display: none" id="re1_title"></div>
<div class="btn" style="height: 15px;margin-top: 10px;display: none" id="re2_title"></div>
<div class="btn" style="height: 15px;margin-top: 10px;display: none" id="re3_title"></div>
</div>
<script src="https://cdn.qjurl.cn/index.js" charset="utf-8"></script>
<script src="https://cdn.qjurl.cn/axios.min.js"></script>
<script type="text/javascript">
function getQueryString(name) {
var reg = new RegExp('(^|&)' + name + '=([^&]*)(&|$)', 'i');
var r = window.location.search.substr(1).match(reg);
if (r != null) {
return unescape(r[2]);
}
return null;
}
function getVideo(height) {
axios.post('https://heedh.cn/get_video', {
id: getQueryString("video")
}).then(function (response) {
if (response.data.code == 1) {
document.title = response.data.title
let player = new Player({
id: 'mse',
autoplay: true,
volume: 0.8,
url: response.data.url,
playsinline: true,
height: window.innerHeight * height,
width: window.innerWidth
});
} else {
alert("404 网页未找到")
}
})
.catch(function (error) {
console.log(error);
});
}
axios.post('https://heedh.cn/video_button/get_config')
.then(function (response) {
let height = 0.70;
for (let i = 0; i < response.data.data.length; i++) {
const s = document.getElementById('re' + (i + 1) + "_title");
if (response.data.data[i].title == "") {
height = height + 0.1
continue;
}
s.innerText = response.data.data[i].title
s.style.display = 'block'
s.onclick = function () {
window.location.href = response.data.data[i].url
}
}
getVideo(height)
})
</script>
</body>
<style>
.btn {
text-align: center;
/ / 水平居中 font-size: 10 px;
background: #eb94d0;
/* 创建渐变 */
background-image: -webkit-linear-gradient(top, #eb94d0, #2079b0);
background-image: -moz-linear-gradient(top, #eb94d0, #2079b0);
background-image: -ms-linear-gradient(top, #eb94d0, #2079b0);
background-image: -o-linear-gradient(top, #eb94d0, #2079b0);
background-image: linear-gradient(to bottom, #eb94d0, #2079b0);
/* 给按钮添加圆角 */
-webkit-border-radius: 28;
-moz-border-radius: 28;
border-radius: 28px;
text-shadow: 3px 2px 1px #9daef5;
-webkit-box-shadow: 6px 5px 24px #666666;
-moz-box-shadow: 6px 5px 24px #666666;
box-shadow: 6px 5px 24px #666666;
font-family: Arial, serif;
color: #fafafa;
font-size: 20px;
padding: 19px;
text-decoration: none;
}
/* 悬停样式 */
/* 悬停样式 */
.btn:hover {
background: #2079b0;
background-image: -webkit-linear-gradient(top, #2079b0, #eb94d0);
background-image: -moz-linear-gradient(top, #2079b0, #eb94d0);
background-image: -ms-linear-gradient(top, #2079b0, #eb94d0);
background-image: -o-linear-gradient(top, #2079b0, #eb94d0);
background-image: linear-gradient(to bottom, #2079b0, #eb94d0);
text-decoration: none;
}
</style>
</html>