bindHkFreeCurrency.blade.php 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280
  1. <!--
  2. /**
  3. * Created by PhpStorm.
  4. * User: z-yang
  5. * Date: 2019/4/11
  6. * Time: 15:33
  7. */
  8. -->
  9. <!DOCTYPE html>
  10. <html lang="en">
  11. <head>
  12. <meta charset="UTF-8" />
  13. <link rel=icon type=image/png href="data:image/png;base64,iVBORw0KGgo=">
  14. <meta
  15. name="viewport"
  16. content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"
  17. />
  18. <meta http-equiv="X-UA-Compatible" content="ie=edge" />
  19. <title>微信阅读小管家福利</title>
  20. <style>
  21. html,
  22. body {
  23. margin: 0 auto;
  24. padding: 0;
  25. max-width: 450px;
  26. font-size: 100px;
  27. }
  28. html {
  29. background: #ff3628;
  30. }
  31. p {
  32. margin: 0;
  33. }
  34. i {
  35. font-style: normal;
  36. }
  37. a{text-decoration: none}
  38. .container {
  39. position: relative;
  40. padding-bottom: .17rem;
  41. }
  42. .container .top_banner {
  43. font-size: 0;
  44. position: relative;
  45. }
  46. .container .top_banner img {
  47. width: 100%;
  48. }
  49. .container .top_banner .u_can_get {
  50. width: 1.5rem;
  51. height: 0.3rem;
  52. font-size: 0.14rem;
  53. line-height: 0.3rem;
  54. text-align: center;
  55. color: #d02a13;
  56. background: -webkit-gradient(linear, left bottom, left top, from(#ffb72c), to(#fff1af));
  57. background: linear-gradient(0deg, #ffb72c, #fff1af);
  58. -webkit-box-shadow: 0px 0.05rem 0.1rem 0px rgba(255, 81, 60, 0.4);
  59. box-shadow: 0px 0.05rem 0.1rem 0px rgba(255, 81, 60, 0.4);
  60. border-radius: 0.15rem;
  61. position: absolute;
  62. left: 4%;
  63. top: 48%;
  64. }
  65. .container .top_banner .u_can_get span {
  66. font-size: 0.17rem;
  67. font-weight: bold;
  68. }
  69. .container .wrap {
  70. font-size: 0;
  71. width: 95%;
  72. margin: 0 auto;
  73. padding-bottom: 0.17rem;
  74. background: -webkit-gradient(linear, left bottom, left top, from(white), to(#fffbe8));
  75. background: linear-gradient(0deg, white, #fffbe8);
  76. -webkit-box-shadow: 0px 0px 0.1rem 0px rgba(0, 0, 0, 0.08);
  77. box-shadow: 0px 0px 0.1rem 0px rgba(0, 0, 0, 0.08);
  78. border-radius: 2px;
  79. }
  80. .container .wrap img {
  81. width: 100%;
  82. }
  83. .container .wrap .to_get {
  84. display:block;
  85. background: #ffdb5f;
  86. color: #8a4b18;
  87. font-size: 0.17rem;
  88. font-weight: bold;
  89. width: 85%;
  90. margin: 0 auto 0.15rem;
  91. padding: 0.15rem 0;
  92. text-align: center;
  93. border-radius: 40px;
  94. }
  95. .container .wrap .get_notice {
  96. font-size: 0.12rem;
  97. color: #666;
  98. text-align: center;
  99. }
  100. .container .wrap .help_wrap {
  101. background: white;
  102. border: 1px solid #d6cea5;
  103. border-radius: 2px;
  104. width: 90%;
  105. margin: 0.54rem auto 0;
  106. padding: 0.16rem 0 0.44rem;
  107. font-size: 0.13rem;
  108. color: #666;
  109. }
  110. .container .wrap .help_wrap p {
  111. padding: 0 0.18rem;
  112. }
  113. .container .wrap .help_wrap .title {
  114. color: #333;
  115. font-size: 0.15rem;
  116. font-weight: bold;
  117. margin-bottom: 0.15rem;
  118. }
  119. .container .wrap .help_wrap .item {
  120. line-height: 1.8;
  121. }
  122. .container .wrap .help_wrap .item i {
  123. color: #ff4930;
  124. font-size: 0.15rem;
  125. font-weight: bold;
  126. }
  127. .alert{
  128. width: 100%;
  129. height: 100%;
  130. position: absolute;
  131. z-index: 100;
  132. left: 0;
  133. top: 0;
  134. overflow: hidden;
  135. background: rgba(0,0,0,.4);
  136. }
  137. .alert .content{
  138. width: 80%;
  139. height: 2rem;
  140. position: absolute;
  141. font-size: .11rem;
  142. left: 50%;
  143. top: 50%;
  144. margin-left: -40%;
  145. margin-top: -40%;
  146. text-align: center;
  147. background: #fff;
  148. }
  149. .alert .content .close{
  150. float: right;
  151. width: .3rem;
  152. height: .3rem;
  153. line-height: .3rem;
  154. border-radius: 50%;
  155. border: 0px solid #ccccd9;
  156. font-size: .2rem;
  157. }
  158. .alert .content p:first-of-type{
  159. margin-top: .5rem;
  160. font-size: .33rem;
  161. }
  162. .alert .content p:nth-of-type(2){
  163. margin-top: .11rem;
  164. font-size: .11rem;
  165. }
  166. .show{
  167. display: block;
  168. }
  169. .hide{
  170. display: none;
  171. }
  172. /*# sourceMappingURL=main.css.map */
  173. </style>
  174. </head>
  175. <body>
  176. <main class="container">
  177. <div class="top_banner">
  178. <img src="https://cdn-novel.iycdm.com/h5/20190411/free_currency_banner.jpg" alt="" />
  179. <p class="u_can_get"><span>200</span>书币 人人有份</p>
  180. </div>
  181. <div class="wrap">
  182. <img src="https://cdn-novel.iycdm.com/h5/20190411/free_currency_wrap.jpg" alt="" />
  183. @if($is_get)
  184. <a class="to_get" href="{{$url}}">马上去看书> ></a>
  185. <p class="get_notice">领取成功 200书币已经到账</p>
  186. @else
  187. <a class="to_get js-get">领取200书币奖励</a>
  188. <p class="get_notice">领取成功后,会自动发放到您的余额中</p>
  189. @endif
  190. <div class="help_wrap">
  191. <p class="title">阅读小管家给您提供优质阅读体验</p>
  192. <div class="help_item">
  193. <p class="item">1.成功添加就送<i>200</i>书币奖励,人人有份;</p>
  194. <p class="item">2.提供最划算充值优惠,看书更便宜;</p>
  195. <p class="item">3.找书快人一步,提供任何您想看的书籍哦;</p>
  196. <p class="item">4.1对1阅读管家优质服务,疑难问题优先解决;</p>
  197. <p class="item">5.更多福利,您想要,我们就有!</p>
  198. </div>
  199. </div>
  200. </div>
  201. </main>
  202. <div class="hide alert">
  203. <div class="content">
  204. <a class="close" title="关闭">&times;</a>
  205. <p>领取成功</p>
  206. <p>200书币已到账</p>
  207. </div>
  208. </div>
  209. </body>
  210. <script>
  211. window.onload=function(){
  212. var d = document;
  213. var is_get = {{$is_get}};
  214. var url = "{{$url}}";
  215. is_get = parseInt(is_get);
  216. var btn = d.querySelector('.js-get');
  217. var get_notice = d.querySelector('.get_notice');
  218. var uid = {{$uid}}
  219. uid = parseInt(uid);
  220. if(is_get){
  221. return ;
  222. }
  223. btn.addEventListener("click",function(){
  224. ajax('POST','/freecurrency',function(){
  225. show();
  226. setTimeout(function () {
  227. get_notice.innerText = '领取成功 200书币已经到账';
  228. btn.innerText = '马上去看书> >';
  229. btn.setAttribute("href",url);
  230. },200);
  231. })
  232. });
  233. close();
  234. function ajax(method,url,callback){
  235. var xhr = new XMLHttpRequest();
  236. xhr.open(method, url, true);
  237. xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
  238. xhr.send('uid='+uid);
  239. xhr.onreadystatechange=function(){
  240. if (xhr.readyState ==4 && xhr.status==200)
  241. {
  242. callback();
  243. }
  244. }
  245. }
  246. function close() {
  247. d.querySelector('.close').addEventListener('click',function () {
  248. d.querySelector('.alert').setAttribute("class","hide alert");
  249. })
  250. }
  251. function show() {
  252. d.querySelector('.alert').setAttribute("class","show alert");
  253. }
  254. }
  255. </script>
  256. </html>