index.html 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <link rel="icon" href="./img/logo.png" type="image/x-icon">
  7. <title>download</title>
  8. <style>
  9. * {
  10. margin: 0;
  11. padding: 0;
  12. }
  13. html,
  14. body {
  15. height: 100%;
  16. width: 100%;
  17. }
  18. body {
  19. background-color: #fff;
  20. overflow-x: hidden;
  21. }
  22. .head {
  23. height: 60%;
  24. text-align: center;
  25. }
  26. .head .bg {
  27. height: 100%;
  28. }
  29. .main {
  30. width: 100%;
  31. height: 100vh;
  32. background-image: url('./img/bg.png');
  33. background-size: 100% 100%;
  34. }
  35. .qr-box {
  36. width: 143px;
  37. height: 143px;
  38. margin: -71px auto 0;
  39. border-radius: 10px;
  40. border: solid 3px #ffffff;
  41. z-index: 99;
  42. position: relative;
  43. }
  44. .btn {
  45. display: block;
  46. width: 219px;
  47. height: 48px;
  48. border-radius: 10px;
  49. border: solid 1px #ffffff;
  50. font-family: SourceHanSansSC-Bold;
  51. font-size: 16px;
  52. letter-spacing: 1px;
  53. margin: 0 auto;
  54. font-weight: bold;
  55. line-height: 48px;
  56. text-indent: 40px;
  57. }
  58. .btn:active{
  59. opacity: .7;
  60. }
  61. .btn.android {
  62. background-color: #9f9b9b;
  63. color: #0d041c;
  64. margin-top: 44px;
  65. }
  66. .btn.iphone {
  67. background-color: #0d041c;
  68. color: #ffffff;
  69. margin-top: 16px;
  70. }
  71. .btn .icon {
  72. height: 20px;
  73. vertical-align: middle;
  74. }
  75. .btn.iphone .icon {
  76. height: 22px;
  77. }
  78. a{
  79. text-decoration: none;
  80. }
  81. .qr-box{
  82. position: relative;
  83. }
  84. .logo{
  85. position: absolute;
  86. width: 24px;
  87. height: 24px;
  88. left: 50%;
  89. top: 50%;
  90. z-index: 2;
  91. margin-left: -12px;
  92. margin-top: -12px;
  93. background: #fff;
  94. border-radius: 4px;
  95. overflow: hidden;
  96. }
  97. #qrBox{
  98. display: inline-block;
  99. border: 4px solid #fff;
  100. font-size: 0;
  101. position: absolute;
  102. left: 50%;
  103. top: 50%;
  104. margin-top: -57px;
  105. margin-left: -57px;
  106. }
  107. #qrBox img{
  108. display: block;
  109. }
  110. </style>
  111. </head>
  112. <body>
  113. <main class="main">
  114. <div class="head">
  115. <img class="bg" src="" alt="">
  116. </div>
  117. <div class="qr-box">
  118. <div id="qrBox"></div>
  119. <img class="logo" src="./img/logo.png" alt="">
  120. </div>
  121. <div id="upload" style="background-color: rgb(0,0,0,0.7);position: fixed;top: 0;width: 100%;height: 100%;z-index: 9999999;display: none;">
  122. <img style="width: 100%;height: 500px;" src="./img/upload.png" alt="">
  123. </div>
  124. <div id="android" class="btn android" onclick="toAndroid()">
  125. <img src="./img/androidicon.png" class="icon" alt="">
  126. Android down</div>
  127. <!-- <div id="ios" class="btn iphone" onclick="toIphone()">
  128. <img src="./img/iosicon.png" class="icon" alt="">
  129. ios download</div> -->
  130. </main>
  131. <script src="https://cdn.bootcdn.net/ajax/libs/qrcodejs/1.0.0/qrcode.min.js"></script>
  132. <script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.5.1/jquery.js"></script>
  133. <script>
  134. // 二维码内容
  135. var qrcode = 'https://www.senyinkj.cn/register/index.html'
  136. new QRCode(document.getElementById('qrBox'), {
  137. text:qrcode,
  138. width: 106,
  139. height: 106,
  140. colorDark: "#000000",
  141. colorLight: "#ffffff",
  142. correctLevel: QRCode.CorrectLevel.H
  143. });
  144. // $.getJSON(serve+'/api/app/getNewestVersion',function(e){
  145. // let data = e.data
  146. // $("#android").attr('href',data.android.url)
  147. // $("#ios").attr('href',data.ios.url)
  148. // })
  149. function toAndroid() {
  150. const bool = navigator.userAgent.toLowerCase().match(/MicroMessenger/i) == 'micromessenger';
  151. if (bool) {
  152. var x = document.getElementById("upload");
  153. x.style.display = "block";
  154. } else {
  155. $.getJSON('https://www.senyinkj.cn/api/version',function(e){
  156. window.location.href = e.data.apk;
  157. })
  158. }
  159. }
  160. function toIphone(){
  161. //window.location.href = window.location.protocol + "//" + window.location.host+'home/download/iosdom.mobileconfig'
  162. }
  163. </script>
  164. </body>
  165. </html>