forked from zuosanmu/WeChat-Jump-to-other-browsers
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
143 lines (129 loc) · 3.8 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
139
140
141
142
143
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
<meta http-equiv="Pragma" content="no-cache" />
<meta http-equiv="Expires" content="0" />
</head>
<body>
<style type="text/css">
* {
margin: 0px;
padding: 0px;
}
img,
button {
display: block;
}
html,
body {
width: 100%;
height: 100%;
overflow: hidden;
}
#show {
width: 100%;
height: 100%;
}
#shade {
position: absolute;
left: 0;
top: 0;
width: 100%;
height: 100%;
background-image: url("open.png");
background-repeat: no-repeat;
background-size: contain;
background-color: rgba(0, 0, 0, 0.7);
}
#hide {
width: 100%;
height: 100%;
}
.mrigin-auto {
margin: 20% auto 0;
}
#btn,
#btn_weixin {
width: 30%;
height: 40px;
font-weight: bold;
outline: none;
}
.text-center {
text-align: center;
margin: 10% 0;
}
.intro {
display: block;
width: 50%;
margin: 10px auto !important;
}
#intro {
width: 100%;
height: 100%;
position: absolute;
left: 0px;
top: 0px;
overflow: scroll;
display: none;
background: rgba(0, 0, 0, 0.6);
}
</style>
<div id="show" style="display:none">
<div id="shade" style="display:none"></div>
<img class="mrigin-auto" id="img_weixin" src="" alt="">
<button class="mrigin-auto" id="btn_weixin">点击下载</button>
</div>
<div id="hide" style="display:block">
<div id="intro">
<img class="intro" src="1.jpg" alt="">
<img class="intro" src="2.jpg" alt="">
<img class="intro" src="3.jpg" alt="">
<img class="intro" src="4.jpg" alt="">
<img class="intro" src="5.jpg" alt="">
<img class="intro" src="6.jpg" alt="">
<img class="intro" src="7.jpg" alt="">
</div>
<img class="mrigin-auto" id="img" src="" alt="">
<button class="mrigin-auto" id="btn">点击下载</button>
</div>
</body>
<script type="text/javascript">
window.onload = function () {
var ua = window.navigator.userAgent.toLowerCase();
var u = navigator.userAgent;
var isAndroid = u.indexOf('Android') > -1 || u.indexOf('Adr') > -1; //android终端
var isiOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/); //ios终端
if (ua.match(/MicroMessenger/i) == 'micromessenger' || u.match(/QQ\//i) == "QQ/"/*u.indexOf('MQQBrowser') !== -1 || u.indexOf('MQQBrowser QQ') !== -1*/) {
document.getElementById("show").style.display = "block";
document.getElementById("hide").style.display = "none";
document.getElementById("img_weixin").src = 'LotterySite_android.png';
document.getElementById("btn_weixin").addEventListener('click', function () {
document.getElementById("shade").style.display = "block";
document.getElementById("btn_weixin").removeEventListener('click');
});
}
if (isAndroid) {
document.getElementById("img").src = 'LotterySite_android.png';
document.getElementById("btn").addEventListener('click', function () {
window.location.href = 'https://139.224.195.129:7788/apk/LotterySite.apk';
document.getElementById("btn").removeEventListener('click');
});
} else {
document.getElementById("img").src = 'LotterySite_ios.png';
document.getElementById("intro").style.display = 'block';
document.getElementById("intro").addEventListener('click', function () {
document.getElementById("intro").style.display = 'none';
document.getElementById("intro").removeEventListener('click');
})
document.getElementById("btn").addEventListener('click', function () {
window.location.href = 'itms-services:///?action=download-manifest&url=https://www.rongqiangu.com:7788/ipa/LotterySite.plist';
document.getElementById("btn").removeEventListener('click');
});
}
}
</script>
<html>