politeness.html 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="viewport" content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
  6. <title>邀请有礼</title>
  7. <link rel="stylesheet" href="../../src/css/me/politeness.css" />
  8. <link rel="stylesheet" href="../../src/css/public.css" />
  9. <link rel="stylesheet" href="../../src/css/bootstrap.css" />
  10. </head>
  11. <body>
  12. <div id="public_img">
  13. <!--<img src="../../img/demand1.jpg" alt="" />-->
  14. <img src="../../img/demand3.png" alt="" class="anut" onclick="javascript:(history.back(-1))"/>
  15. <div>邀请好友 共赢技淘币</div>
  16. </div>
  17. <div class="politeness">
  18. <img src="../../img/politeness1.png" alt="" />
  19. <img src="../../img/politeness2.png" alt="" />
  20. <div class="cont">
  21. <div>
  22. <p>
  23. 1.注册即送200技淘币
  24. </p>
  25. <p>
  26. 2.前500名注册客户,立送两万技淘币
  27. </p>
  28. </div>
  29. <img src="../../img/politeness3.png" alt="" />
  30. </div>
  31. <div class="myPo">
  32. <span>我的邀请码:</span>
  33. <span></span>
  34. </div>
  35. <div class="click">
  36. 立即邀请客户
  37. </div>
  38. </div>
  39. <div class="tc">
  40. <div class="all" >
  41. <div onclick="call('qqFriend')">
  42. <img src="../../img/qq.png" alt="" />
  43. <p>QQ</p>
  44. </div>
  45. <div onclick="call('wechatFriend')">
  46. <img src="../../img/wechat.png" alt="" class="maxI"/>
  47. <p>
  48. 微信好友
  49. </p>
  50. </div>
  51. <div onclick="call('wechatTimeline')">
  52. <img src="../../img/wechat_moments.png" alt="" />
  53. <p>微信朋友圈</p>
  54. </div>
  55. <div onclick="call('weibo')">
  56. <img src="../../img/sina_weibo.png" alt="" class="maxI"/>
  57. <p>新浪微博</p>
  58. </div>
  59. </div>
  60. <div class="allNo">
  61. 取消
  62. </div>
  63. </div>
  64. </body>
  65. <script type="text/javascript" src="http://apps.bdimg.com/libs/jquery/2.1.1/jquery.js"></script>
  66. <script type="text/javascript" src="http://cdn.bootcss.com/bootstrap/3.3.5/js/bootstrap.min.js"></script>
  67. <script src="../../src/js/NativeShare.js"></script>
  68. <script src="../../src/js/public.js"></script>
  69. <script src="../../src/js/me/politeness.js"></script>
  70. <script type="text/javascript">
  71. //请求数据
  72. function getData(method,url,data){
  73. var menuArr=[];
  74. $.ajax({
  75. method: method,
  76. dataType: "json",
  77. async:false, //false同步、true异步
  78. //url: "http://uat.jishutao.com"+url,
  79. url: "http://www.jishutao.com"+url,
  80. //url: "http://192.168.0.99:8080"+url,
  81. xhrFields:{withCredentials: true},
  82. crossDomain:true,
  83. data: data,
  84. success:function(data){
  85. if (!data.data) {
  86. if (data.error && data.error.length) {
  87. };
  88. };
  89. menuArr=data;
  90. }
  91. })
  92. return menuArr;
  93. }
  94. //获取数据
  95. var data={};
  96. var datas=getData("get","/api/user/InvitationCode",data);
  97. //填充数据
  98. $(".myPo>span:nth-child(2)").html(datas.data);
  99. //分享
  100. var nativeShare = new NativeShare();
  101. var shareData = {
  102. title: '注册即送豪礼,二千万技淘币等你来拿。全国20家资深服务商联合邀请您参与...',
  103. desc: '等您来拿,全国20家资深服务商联合赠送',
  104. // 如果是微信该link的域名必须要在微信后台配置的安全域名之内的。
  105. link:"http://m.jishutao.com/1.0/template/me/request.html?code="+datas.data,
  106. icon:"http://m.jishutao.com/1.0/template/me/request.html?code="+datas.data,
  107. // 不要过于依赖以下两个回调,很多浏览器是不支持的
  108. success: function() {
  109. console.log("success")
  110. },
  111. fail: function() {
  112. console.log("fail")
  113. }
  114. }
  115. nativeShare.setShareData(shareData)
  116. function call(command) {
  117. try {
  118. nativeShare.call(command)
  119. } catch (err) {
  120. // 如果不支持,你可以在这里做降级处理
  121. console.log(err.message)
  122. // console.log("err.message")
  123. }
  124. }
  125. </script>
  126. <!--友盟-->
  127. <script type="text/javascript">
  128. var cnzz_protocol = (("https:" == document.location.protocol) ? " https://" : " http://");document.write(unescape("%3Cspan id='cnzz_stat_icon_1274675010'%3E%3C/span%3E%3Cscript src='" + cnzz_protocol + "s13.cnzz.com/z_stat.php%3Fid%3D1274675010' type='text/javascript'%3E%3C/script%3E"));
  129. </script>
  130. <!--百度商桥-->
  131. <!-- <script language="javascript" src="http://put.zoosnet.net/JS/LsJS.aspx?siteid=PUT70876498&float=1&lng=cn"></script>-->
  132. <!-- <script>-->
  133. <!-- var _hmt = _hmt || [];-->
  134. <!-- (function() {-->
  135. <!-- var hm = document.createElement("script");-->
  136. <!-- hm.src = "https://hm.baidu.com/hm.js?4f14b647ef81bc71f1a3fd13c098a0b4";-->
  137. <!-- var s = document.getElementsByTagName("script")[0]; -->
  138. <!-- s.parentNode.insertBefore(hm, s);-->
  139. <!-- })();-->
  140. <!-- </script>-->
  141. </html>