index.html 9.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302
  1. <!DOCTYPE html>
  2. <html lang="zh-CN">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  5. <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  6. <meta name="viewport" content="width=640, user-scalable=no, target-densitydpi=device-dpi">
  7. <link rel="shortcut icon" href="./favicon.ico" type="image/x-icon">
  8. <title>热血之刃</title>
  9. <script src="./js/jquery.min.js"></script>
  10. <script src="./js/ua-parser.min.js"></script>
  11. <style>
  12. * {
  13. padding: 0;
  14. margin: 0;
  15. touch-action: none;
  16. touch-action: pan-y;
  17. }
  18. html,
  19. body {
  20. height: 100%;
  21. }
  22. a {
  23. text-decoration: none;
  24. }
  25. .wrap {
  26. position: relative;
  27. max-width: 640px;
  28. margin: 0 auto;
  29. }
  30. img {
  31. display: block;
  32. width: 100%;
  33. margin-top: -1px;
  34. }
  35. video {
  36. margin-top: -1px;
  37. }
  38. .fixed_url {
  39. z-index: 99;
  40. position: fixed;
  41. min-width: 640px;
  42. width: 100%;
  43. }
  44. .fixed_url a {
  45. width: 33.33%;
  46. height: 100%;
  47. position: absolute;
  48. right: 0;
  49. top: 0;
  50. }
  51. .fixed_game {
  52. position: absolute;
  53. display: flex;
  54. top: 50%;
  55. transform: translateY(-50%);
  56. padding: 15px 24px;
  57. }
  58. .fixed_game img {
  59. width: 80px;
  60. height: 80px;
  61. border-radius: 10px;
  62. }
  63. .fixed_game_in {
  64. padding: 8px 12px;
  65. }
  66. .fixed_gamename {
  67. font-weight: bold;
  68. font-size: 25px;
  69. width: 150px;
  70. white-space: nowrap;
  71. overflow: hidden;
  72. text-overflow: ellipsis;
  73. }
  74. .fixed_gamepromo {
  75. width: 300px;
  76. font-size: 23px;
  77. display: -webkit-box;
  78. -webkit-box-orient: vertical;
  79. -webkit-line-clamp: 1;
  80. overflow: hidden;
  81. }
  82. #weixin_tips {
  83. display: none;
  84. position: fixed;
  85. left: 0;
  86. right: 0;
  87. top: 0;
  88. bottom: 0;
  89. z-index: 99;
  90. max-width: 640px;
  91. margin: 0 auto;
  92. background-color: rgba(0, 0, 0, 0.5);
  93. }
  94. #exit_window {
  95. display: none;
  96. position: fixed;
  97. top: 0;
  98. left: 0;
  99. width: 100%;
  100. height: 100%;
  101. z-index: 999;
  102. background: rgba(0, 0, 0, 0.8);
  103. }
  104. #exit_window span {
  105. display: block;
  106. width: 100%;
  107. height: calc((100% - 600px) / 2);
  108. }
  109. #dialog {
  110. margin-top: 200px;
  111. position: absolute;
  112. width: 72%;
  113. left: 0;
  114. right: 0;
  115. margin: 0 auto;
  116. top: 25%;
  117. }
  118. </style>
  119. <script>
  120. const CONFIG = {
  121. downloadApk: "https://game.jhfly.cn/download/rxzr14.apk",
  122. androidJumpUrl: "https://game.jhfly.cn",
  123. iosJumpUrl: "https://h5.jhfly.cn/rxzr/"
  124. }
  125. var ua = navigator.userAgent;
  126. var ipad = ua.match(/(iPad).*OS\s([\d_]+)/);
  127. var isIphone = !ipad && ua.match(/(iPhone\sOS)\s([\d_]+)/);
  128. var iosclick = '';
  129. var isIos = ipad || isIphone;
  130. var gid;
  131. function setStatScript(url) {
  132. if (url) {
  133. var script = document.createElement('script'),
  134. body = document.body || document.getElementsByTagName("body")[0] || document.documentElement;
  135. with(script) {
  136. src = url,
  137. type = 'text/javascript',
  138. async = 'async'
  139. }
  140. body.appendChild(script);
  141. }
  142. }
  143. function tjcheck() {
  144. if (isIos) {
  145. window.location.href = CONFIG.iosJumpUrl
  146. } else {
  147. download(CONFIG.downloadApk);
  148. setTimeout(() => {
  149. window.location.href = CONFIG.androidJumpUrl;
  150. }, 100);
  151. }
  152. }
  153. function isWeiXin() {
  154. var ua = window.navigator.userAgent.toLowerCase();
  155. if (ua.match(/MicroMessenger/i) == 'micromessenger') {
  156. return true;
  157. } else {
  158. return false;
  159. }
  160. }
  161. function weixin_tips() {
  162. document.getElementById('weixin_tips').style.display = 'block';
  163. }
  164. function download(url) {
  165. const link = document.createElement("a");
  166. link.href = url;
  167. link.target = "_blank";
  168. link.style.display = "none";
  169. document.body.append(link);
  170. link.click();
  171. }
  172. </script>
  173. </head>
  174. <body>
  175. <div class="wrap">
  176. <a href="#" onclick="tjcheck();" class="link">
  177. <img src="./images/NO.1.gif" alt class="img100">
  178. <img src="./images/NO.2.gif" alt class="img100">
  179. </a>
  180. <!-- poster="/wap/img/njrz/https://img2.tst.cn/issue_activity/20210413/cbd7ce98c227f62ae4682a71a7700a45.jpg" -->
  181. <video id="video" class="video" src="media/NO3.mp4" style="width: 100%;object-fit:fill;" x-webkit-airplay="true" webkit-playsinline="true" playsinline="true" x5-playsinline x5-video-player-type="h5" x5-video-player-fullscreen x5-video-orientation="portraint"
  182. preload="auto" controls>您的浏览器不支持 video
  183. 标签。</video>
  184. <a href="#" onclick="tjcheck();" class="link">
  185. <img src="./images/NO4.png" alt class="img100">
  186. </a>
  187. <div style="background:black;text-align: center;width: 100%;height: 106px;"></div>
  188. </div>
  189. <!-- 底部固定框 -->
  190. <div class="fixed_url" style=" bottom:0; ;">
  191. <a href="#" onclick="tjcheck();" class="link"></a>
  192. <img src="./images/1.png" alt style="width: 100%">
  193. <div class="fixed_game">
  194. <img src="./images/icon.png">
  195. <div class="fixed_game_in">
  196. <div class="fixed_gamename" style="color:#FFFFFF"> 热血之刃 </div> <span class="fixed_gamepromo" style="color:#FFFFFF"> 全网独家打金服,来玩就送V20! </span>
  197. </div>
  198. </div>
  199. </div>
  200. <!-- 弹框 -->
  201. <div id="exit_window">
  202. <span class="closeBtn"></span>
  203. <div id="dialog">
  204. <a href="#" onclick="tjcheck();" class="link">
  205. <img src="./images/2.png" style="width: 100%;pointer-events: none"> </a>
  206. <a class="closeBtn" style="display: block;position: absolute;top: 0;right: 0;height: 1.9rem;width: 1.9rem;padding: .6rem;">
  207. <img src="./images/exit_close1.png" alt style="position: absolute;top: 0;right: 0;height: 1.9rem;width: 1.9rem;padding: .6rem;pointer-events: none">
  208. </a>
  209. </div>
  210. <span class="closeBtn" style="margin-top: 600px;"></span>
  211. </div>
  212. <div id="weixin_tips">
  213. <img src="./images/wx_pup.png" alt class="img100">
  214. </div>
  215. <!-- 滚动弹窗 -->
  216. <script>
  217. var step = 0;
  218. var index = 60;
  219. (function() {
  220. if (isWeiXin()) {
  221. weixin_tips();
  222. } else {
  223. // setStatScript(tjurl);
  224. // tjcheck();
  225. // $('.link').attr("href", CONFIG.iosJumpUrl);
  226. if (!isIos) {
  227. // window.location.href = CONFIG.androidJumpUrl;
  228. }
  229. }
  230. var startX;
  231. var startY;
  232. window.addEventListener("touchstart", function(e) {
  233. startX = e.changedTouches[0].pageX;
  234. startY = e.changedTouches[0].pageY;
  235. });
  236. navigator.vibrate = navigator.vibrate || navigator.webkitVibrate || navigator.mozVibrate || navigator.msVibrate;
  237. if (navigator.vibrate) {
  238. console.log("支持设备震动!");
  239. }
  240. window.addEventListener("touchmove", function(e) {
  241. // 判断默认行为是否可以被禁用
  242. if (e.cancelable) {
  243. // 判断默认行为是否已经被禁用
  244. if (!e.defaultPrevented) {
  245. e.preventDefault();
  246. }
  247. }
  248. moveEndX = e.changedTouches[0].pageX;
  249. moveEndY = e.changedTouches[0].pageY;
  250. X = moveEndX - startX;
  251. Y = moveEndY - startY;
  252. //左滑 //右滑
  253. if ((X > 0 && Math.abs(X) > Math.abs(Y)) || (X < 0 && Math.abs(X) > Math.abs(Y))) {
  254. $('#exit_window').show();
  255. setTimeout(function() {
  256. if (window.navigator.vibrate) {
  257. window.navigator.vibrate([200, 100, 200]);
  258. }
  259. }, 100)
  260. }
  261. return false;
  262. });
  263. // 点击关闭弹框
  264. $('.closeBtn').click(function() {
  265. $('#exit_window').hide();
  266. })
  267. })();
  268. </script>
  269. </body>
  270. </html>