问星数据dist打包,线上使用; 源码在bigData仓库

index.html 21KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta content="no" name="apple-mobile-web-app-capable">
  6. <title>问星数据 — 短视频及直播数据服务平台</title>
  7. <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0,minimum-scale=1.0,user-scalable=0" />
  8. <meta name="keywords" content="问星数据,视频号数据,快手数据,抖音数据,直播带货数据,热门创意数据,微信视频号数据">
  9. <meta name="description" content="问星数据是行业领先的并且免费的短视频数据服务平台,提供视频号数据,快手数据,抖音数据;包含视频号创意、红人粉丝画像、直播带货数据、热门创意等,可以实时监控直播带货及直播带货商品销售数据,为从业者提供大量短视频及直播电商相关数据">
  10. <link rel="stylesheet" type="text/css" href="./common/reset.css"/>
  11. <link rel="stylesheet" type="text/css" href="./common/animate.min.css"/>
  12. <link rel="stylesheet" type="text/css" href="./common/swiper.min.css"/>
  13. <script type="text/javascript" src="./common/swiper.animate.min.js"></script>
  14. <script src="./common/swiper.min.js"></script>
  15. <script src="./common/jquery-3.0.0.min.js"></script>
  16. <script>
  17. var _hmt = _hmt || [];
  18. (function() {
  19. var hm = document.createElement("script");
  20. hm.src = "https://hm.baidu.com/hm.js?d61b9e2caf4d46ccda7471b5385e2333";
  21. var s = document.getElementsByTagName("script")[0];
  22. s.parentNode.insertBefore(hm, s);
  23. })();
  24. </script>
  25. <script>
  26. (function(){
  27. var src = "https://s.ssl.qhres2.com/ssl/ab77b6ea7f3fbf79.js";
  28. document.write('<script src="' + src + '" id="sozz"><\/script>');
  29. })();
  30. </script>
  31. <script>
  32. (function(){
  33. var bp = document.createElement('script');
  34. var curProtocol = window.location.protocol.split(':')[0];
  35. if (curProtocol === 'https') {
  36. bp.src = 'https://zz.bdstatic.com/linksubmit/push.js';
  37. }
  38. else {
  39. bp.src = 'http://push.zhanzhang.baidu.com/push.js';
  40. }
  41. var s = document.getElementsByTagName("script")[0];
  42. s.parentNode.insertBefore(bp, s);
  43. })();
  44. </script>
  45. <script src="https://res.wx.qq.com/open/js/jweixin-1.6.0.js"></script>
  46. <script type="text/javascript">
  47. document.documentElement.style.fontSize = 100 * (document.documentElement.clientWidth/375) + "px";
  48. window.onresize = function(){
  49. document.documentElement.style.fontSize = 100 * (document.documentElement.clientWidth/375) + "px";
  50. }
  51. function parseQueryString(key) {
  52. var urlObj = {};
  53. var reg = /([^?=&]+)=([^?=&]+)/g;
  54. (window.location.href).replace(reg, ($0, $1, $2) => {
  55. urlObj[$1] = decodeURIComponent($2);
  56. })
  57. return urlObj[key];
  58. }
  59. function userAgent () {
  60. var u = navigator.userAgent.toLowerCase();
  61. if(u.match(/micromessenger/i)){return '微信浏览器'}
  62. if(u.indexOf('baidu')>0){return '百度浏览'}
  63. if(u.indexOf('qqbrowser')>0){return 'qq浏览'}
  64. if(u.indexOf('ucbrowser')>0){return 'uc浏览器'}
  65. if(u.indexOf('opera')>0){return 'Opera浏览器'}
  66. if(u.indexOf('firefox')>0){return 'Firefox浏览器'}
  67. if(u.indexOf('chrome')>0&&u.indexOf('safari')>0){return 'Chrome浏览器'}
  68. if(u.indexOf('safari')>0&&u.indexOf('chrome') == -1){return 'Safari浏览器'}
  69. if(u.indexOf('compatible')>0&&u.indexOf('msie') > -1&&u.indexOf('opera')==-1){return 'IE浏览器'}
  70. if(u.indexOf('windows nt 6.1; trident/7.0;')>0&&!(u.indexOf('compatible')>0&&u.indexOf('msie') > -1&&u.indexOf('opera')==-1)){return 'IE的Edge浏览器'}
  71. }
  72. function burialPoint({project_name,button_name,url_value,page_name,key_value,browser}){//埋点
  73. $.ajax({
  74. type: "post",
  75. url: "/wx_sph/api/burialPoint/add",
  76. data:{
  77. project_name : project_name,
  78. button_name : button_name,
  79. url_value : url_value,
  80. page_name: page_name,
  81. key_value: key_value,
  82. browser: browser
  83. },
  84. success:function(res){
  85. if(res.errno == "0" && res.rst){
  86. }
  87. },
  88. error:function(err){
  89. console.log(err)
  90. }
  91. })
  92. }
  93. burialPoint({project_name:'移动端h5',button_name:'进入页面',key_value:parseQueryString('key')?parseQueryString('key'):'',page_name:'推广落地页',url_value:window.location.href,browser:userAgent()})
  94. _hmt?_hmt.push(['_trackEvent','移动端h5', '进入页面', parseQueryString('key')?parseQueryString('key'):'','']):'';
  95. // if(!(navigator.userAgent.match(/(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i))&&!navigator.userAgent.toLowerCase().match(/micromessenger/i)) {
  96. // window.location.href = "https://www.wenxingshuju.com";
  97. // }
  98. </script>
  99. <link rel="stylesheet" href="./common/common.css?v=1">
  100. <script>
  101. if((navigator.userAgent.match(/(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i))&&navigator.userAgent.toLowerCase().match(/micromessenger/i)) {
  102. // 微信api
  103. function navlistData(){
  104. $.ajax({
  105. type:"get",
  106. url: 'https://www.wenxingshuju.com/wx_sph/api/wechat/jsApiConfig?url='+encodeURI(window.location.href),
  107. dataType:"json",
  108. success:function(res) {
  109. if(res.errno == 0 && res.rst){
  110. console.log(res)
  111. wx.config({
  112. debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
  113. appId: res.rst.appId, // 必填,公众号的唯一标识
  114. timestamp: res.rst.timestamp, // 必填,生成签名的时间戳
  115. nonceStr: res.rst.nonceStr, // 必填,生成签名的随机串
  116. signature: res.rst.signature, // 必填,签名
  117. jsApiList: [
  118. "updateTimelineShareData",
  119. "updateAppMessageShareData",
  120. "onMenuShareWeibo",
  121. "checkJsApi"
  122. ], // 必填,需要使用的JS接口列表
  123. openTagList:['wx-open-launch-weapp']
  124. });
  125. wx.ready(function() {
  126. //config信息验证后会执行ready方法,所有接口调用都必须在config接口获得结果之后,config是一个客户端的异步操作,所以如果需要在页面加载时就调用相关接口,则须把相关接口放在ready函数中调用来确保正确执行。对于用户触发时才调用的接口,则可以直接调用,不需要放在ready函数中
  127. });
  128. wx.error(function(res) {
  129. console.log('res',res);
  130. // config信息验证失败会执行error函数,如签名过期导致验证失败,具体错误信息可以打开config的debug模式查看,也可以在返回的res参数中查看,对于SPA可以在这里更新签名。
  131. });
  132. }
  133. }
  134. })
  135. }
  136. navlistData()
  137. }
  138. </script>
  139. </head>
  140. <style>
  141. body{
  142. height: 100vh;
  143. overflow: hidden;
  144. padding: 0;
  145. background: #FFFFFF;
  146. }
  147. .container{font-size: 0.18rem;height: 100vh;}
  148. .swiper-container {width: 100%;height: 100%;background:#FFFFFF;top:0;}
  149. .swiper-container{
  150. position: absolute!important;
  151. }
  152. .swiper-slide{width:100%;height:100%;background:#FFFFFF;}
  153. img{display:block;}
  154. .ani{
  155. position:absolute;
  156. }
  157. .swiper-pagination-bullet {
  158. width: 6px !important;
  159. height: 6px !important;
  160. background: #ccc !important;
  161. opacity: .4 !important;
  162. }
  163. .swiper-pagination-bullet-active {
  164. opacity: 1 !important;
  165. background: #2762FF !important;
  166. }
  167. .phone_logo{
  168. width: 0.78rem;
  169. height: 0.3rem;
  170. margin-top: 0.21rem;
  171. margin-left: 0.19rem;
  172. }
  173. .bigTitle{
  174. color: #1F1C43;
  175. font-size: 0.3rem;
  176. line-height: 0.4rem;
  177. font-weight: bold;
  178. text-align: center;
  179. margin-top: 0.4rem;
  180. }
  181. .smallTitle{
  182. color: #1F1C43;
  183. font-size: 0.18rem;
  184. line-height: 0.4rem;
  185. letter-spacing: 0.08rem;
  186. text-align: center;
  187. }
  188. .smallTitle span{
  189. font-size: 0.18rem;
  190. color: #FF3600;
  191. }
  192. .pc_link, .pc_link a{
  193. color: #848298;
  194. font-size: 0.14rem;
  195. line-height: 0.22rem;
  196. text-align: center;
  197. }
  198. .pc_link a{
  199. text-decoration: underline;
  200. }
  201. .phone_page_1{
  202. width: 100%;
  203. min-height: 2.78rem;
  204. }
  205. .phone_page_box{
  206. width: 2.10rem;
  207. margin: auto;
  208. margin-top: 5vh;
  209. position: relative;
  210. }
  211. .phone_page_box .phone_small{
  212. position: absolute;
  213. top: 30%;
  214. width: 3rem;
  215. left: 50%;
  216. transform: translateX(-50%);
  217. }
  218. .phone_page_box .phone_small .img_button{
  219. width: 1.39rem;
  220. position: absolute;
  221. top: 0.7rem;
  222. left: 0;
  223. right: 0;
  224. margin: auto;
  225. }
  226. .phone_page_box .phone_small .img_button1{
  227. width: 2.4rem;
  228. top: -0.2rem;
  229. }
  230. .phone_page_box .phone_small .img_button img{
  231. width: 100%;
  232. position: relative;
  233. z-index: 1;
  234. }
  235. .phone_page_box .phone_small .img_button::after{
  236. content: '';
  237. width: 0.12rem;
  238. height: 0.12rem;
  239. border-radius: 50%;
  240. background: rgba(0,0,0,0.5);
  241. display: block;
  242. position: absolute;
  243. top: -0.03rem;
  244. left: 0;
  245. right: 0;
  246. margin: auto;
  247. -webkit-animation: button 1.5s infinite ease-in-out;
  248. }
  249. .phone_page_box .phone_small .img_button1::after{
  250. content: '';
  251. width: 0.12rem;
  252. height: 0.12rem;
  253. border-radius: 50%;
  254. background: rgba(0,0,0,0.5);
  255. display: block;
  256. position: absolute;
  257. top: auto;
  258. bottom: -0.04rem;
  259. left: 0.11rem;
  260. right: 0;
  261. margin: auto;
  262. -webkit-animation: button 1.5s infinite ease-in-out;
  263. }
  264. .phone_page_box .phone_small .img{
  265. width: 100%;
  266. }
  267. .phone_page{
  268. width: 100%;
  269. min-height: 2.78rem;
  270. }
  271. .open_button{
  272. width: 2.80rem;
  273. height: 0.50rem;
  274. background: linear-gradient(270deg, #FF8B4F 0%, #FF5227 100%);
  275. border-radius: 0.10rem;
  276. position: relative;
  277. display: block;
  278. top: 5.6rem;
  279. left: 0;
  280. right: 0;
  281. margin: auto;
  282. border: none;
  283. color: #FFFFFF;
  284. font-size: 0.16rem;
  285. z-index: 99;
  286. text-align: center;
  287. line-height: 0.5rem;
  288. /* -webkit-animation: button 1.5s infinite ease-in-out; */
  289. }
  290. @-webkit-keyframes button {
  291. 0% {transform: scale(1.2);}
  292. 50% {transform: scale(1);}
  293. 100% {transform: scale(1.2);}
  294. }
  295. @-moz-keyframes button {
  296. 0% {transform: scale(0.9);}
  297. 50% {transform: scale(1);}
  298. 100% {transform: scale(0.9);}
  299. }
  300. @keyframes button {
  301. 0% {transform: scale(1.2);}
  302. 50% {transform: scale(1);}
  303. 100% {transform: scale(1.2);}
  304. }
  305. #array{
  306. position:absolute;z-index:999;-webkit-animation: start 1.5s infinite ease-in-out;width: 0.22rem;bottom: 1rem;left: 0;right: 0;margin: auto;
  307. }
  308. @-webkit-keyframes start {
  309. 0% {opacity: 0;transform: translate(0,100px);}
  310. 50% {opacity: 1;transform: translate(0,0);}
  311. 100% {opacity: 0;transform: translate(0,-28px);}
  312. }
  313. @-moz-keyframes start {
  314. 0% {opacity: 0;transform: translate(0,100px);}
  315. 50% {opacity: 1;transform: translate(0,0);}
  316. 100% {opacity: 0;transform: translate(0,-28px);}
  317. }
  318. @keyframes start {
  319. 0% {opacity: 0;transform: translate(0,100px);}
  320. 50% {opacity: 1;transform: translate(0,0);}
  321. 100% {opacity: 0;transform: translate(0,-28px);}
  322. }
  323. #launch-btn{
  324. display: none;
  325. }
  326. </style>
  327. <body>
  328. <div class="container">
  329. <button class="open_button" id="commonButton" onclick="openWxApplet('weixin://dl/business/?t=o3aIVwrmPmt')">打开问星数据小程序</button>
  330. <wx-open-launch-weapp id="launch-btn" username="gh_7b8ac119fda1" path="/pages/index/index?source=h5_wx" class="open_button">
  331. <script type="text/wxtag-template">
  332. <style>
  333. .btn{display: block;margin:auto;font-size:16px;line-height:50px;text-align:center;background:transparent;border:none;color:#ffffff;}
  334. </style>
  335. <button class="btn">打开小程序</button>
  336. </script>
  337. </wx-open-launch-weapp>
  338. <div class="swiper-container">
  339. <div class="swiper-wrapper">
  340. <section class="swiper-slide swiper-slide1">
  341. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/phone_logo.png" class="phone_logo" alt="">
  342. <h1 class="bigTitle">视频号数据实时分析</h1>
  343. <div class="phone_page_box">
  344. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/phone1_1.png" class="phone_page">
  345. <div class="phone_small">
  346. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/phone1_1_1.png" class="img">
  347. <div class="img_button">
  348. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/phone1_1_2.png">
  349. </div>
  350. </div>
  351. </div>
  352. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/arrow.png" id="array" class="resize">
  353. </section>
  354. <section class="swiper-slide swiper-slide1">
  355. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/phone_logo.png" class="phone_logo" alt="">
  356. <h1 class="bigTitle">直播带货数据分析</h1>
  357. <div class="phone_page_box">
  358. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/phone1_2.png" class="phone_page">
  359. <div class="phone_small">
  360. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/phone1_2_1.png" class="img">
  361. <div class="img_button">
  362. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/phone1_2_2.png">
  363. </div>
  364. </div>
  365. </div>
  366. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/arrow.png" id="array" class="resize">
  367. </section>
  368. <section class="swiper-slide swiper-slide1">
  369. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/phone_logo.png" class="phone_logo" alt="">
  370. <h1 class="bigTitle">视频号行业趋势动态</h1>
  371. <div class="phone_page_box">
  372. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/phone1_3.png" class="phone_page">
  373. <div class="phone_small">
  374. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/phone1_3_1.png" class="img">
  375. <div class="img_button img_button1">
  376. <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/phone1_3_2.png">
  377. </div>
  378. </div>
  379. </div>
  380. <!-- <img src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/arrow.png" id="array" class="resize"> -->
  381. </section>
  382. </div>
  383. <div class="swiper-pagination"></div>
  384. </div>
  385. <!-- 弹框 -->
  386. <input id="copy_1" type="text" readOnly="true" value=""/>
  387. <div id="copy_2"></div>
  388. <text id="copyCon"></text>
  389. <div class="mask" id="mask">
  390. <div class="content">
  391. <img src="./img/close.png" class="close" onclick="$('#mask').hide()"/>
  392. <div class="title">
  393. 微信搜索<span style="color:#FF5A14;">问星数据</span>小程序
  394. </div>
  395. <div class="title">免费查看更多视频号数据</div>
  396. <image src="https://kx-bigdata.oss-cn-beijing.aliyuncs.com/phone/h5_mask.png" mode="widthFix" class="image"></image>
  397. <button type="default" class="copyButton" onclick="copyPassword()">第一步:点击复制【问星数据】</button>
  398. <button type="default" class="copyButton" onclick="copyPassword('open')" style="margin-top: 0.18rem;">第二步:打开微信</button>
  399. <p class="hint">如无法跳转,请手动打开微信APP</p>
  400. </div>
  401. </div>
  402. </div>
  403. <div class="alert-info" style="display: none;">
  404. <!-- tip提示,3s后消失 -->
  405. <p></p>
  406. </div>
  407. </body>
  408. </html>
  409. <script>
  410. var scaleW = window.innerWidth / 320;
  411. var scaleH = window.innerHeight / 480;
  412. var resizes = document.querySelectorAll('.resize');
  413. for (var j = 0; j < resizes.length; j++) {
  414. resizes[j].style.width = parseInt(resizes[j].style.width) * scaleW + 'px';
  415. resizes[j].style.height = parseInt(resizes[j].style.height) * scaleH + 'px';
  416. resizes[j].style.top = parseInt(resizes[j].style.top) * scaleH + 'px';
  417. resizes[j].style.left = parseInt(resizes[j].style.left) * scaleW + 'px';
  418. }
  419. var mySwiper = new Swiper('.swiper-container', {
  420. direction: 'vertical',
  421. pagination: '.swiper-pagination',
  422. //virtualTranslate : true,
  423. mousewheelControl: true,
  424. onInit: function (swiper) {
  425. swiperAnimateCache(swiper);
  426. swiperAnimate(swiper);
  427. },
  428. onSlideChangeEnd: function (swiper) {
  429. swiperAnimate(swiper);
  430. },
  431. onTransitionEnd: function (swiper) {
  432. swiperAnimate(swiper);
  433. },
  434. watchSlidesProgress: true,
  435. onProgress: function (swiper) {
  436. for (var i = 0; i < swiper.slides.length; i++) {
  437. var slide = swiper.slides[i];
  438. var progress = slide.progress;
  439. var translate = progress * swiper.height / 4;
  440. scale = 1 - Math.min(Math.abs(progress * 0.5), 1);
  441. var opacity = 1 - Math.min(Math.abs(progress / 2), 0.5);
  442. slide.style.opacity = opacity;
  443. es = slide.style;
  444. es.webkitTransform = es.MsTransform = es.msTransform = es.MozTransform = es.OTransform = es.transform = 'translate3d(0,' + translate + 'px,-' + translate + 'px) scaleY(' + scale + ')';
  445. }
  446. },
  447. onSetTransition: function (swiper, speed) {
  448. for (var i = 0; i < swiper.slides.length; i++) {
  449. es = swiper.slides[i].style;
  450. es.webkitTransitionDuration = es.MsTransitionDuration = es.msTransitionDuration = es.MozTransitionDuration = es.OTransitionDuration = es.transitionDuration = speed + 'ms';
  451. }
  452. },
  453. })
  454. if((navigator.userAgent.match(/(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i))&&navigator.userAgent.toLowerCase().match(/micromessenger/i)) {
  455. document.getElementById('launch-btn').style.display='block';
  456. document.getElementById('commonButton').style.display='none';
  457. var btn = document.getElementById('launch-btn');
  458. btn.addEventListener('launch', function (e) {
  459. burialPoint({project_name:'移动端h5',button_name:'微信端点击按钮',key_value:parseQueryString('key')?parseQueryString('key'):'',page_name:'推广落地页',url_value:window.location.href,browser:userAgent()})
  460. _hmt?_hmt.push(['_trackEvent','移动端h5', '微信端点击按钮', parseQueryString('key')?parseQueryString('key'):'','']):'';
  461. });
  462. btn.addEventListener('error', function (e) {
  463. burialPoint({project_name:'移动端h5',button_name:'微信端点击按钮1',key_value:parseQueryString('key')?parseQueryString('key'):'',page_name:'推广落地页',url_value:window.location.href,browser:userAgent()})
  464. _hmt?_hmt.push(['_trackEvent','移动端h5', '微信端点击按钮1', parseQueryString('key')?parseQueryString('key'):'','']):'';
  465. });
  466. }
  467. window.onload = function(){
  468. }
  469. function openWxApplet(scheme){
  470. var sUserAgent = navigator.userAgent.toLowerCase();
  471. if(sUserAgent.indexOf("baidu") > 0 || sUserAgent.indexOf("ucbrowser") > 0 ) {
  472. $('#mask').show()
  473. burialPoint({project_name:'移动端h5',button_name:'点击打开弹框',key_value:parseQueryString('key')?parseQueryString('key'):'',page_name:'推广落地页',url_value:window.location.href,browser:userAgent()})
  474. _hmt?_hmt.push(['_trackEvent','移动端h5', '点击打开弹框', parseQueryString('key')?parseQueryString('key'):'','']):'';
  475. }else{
  476. location.href = scheme;
  477. burialPoint({project_name:'移动端h5',button_name:'页面按钮直接打开微信',key_value:parseQueryString('key')?parseQueryString('key'):'',page_name:'推广落地页',url_value:window.location.href,browser:userAgent()})
  478. _hmt?_hmt.push(['_trackEvent','移动端h5', '页面按钮直接打开微信', parseQueryString('key')?parseQueryString('key'):'','']):'';
  479. }
  480. }
  481. function copyPassword(type) {
  482. if(type=='open'){//第二步,打开微信
  483. burialPoint({project_name:'移动端h5',button_name:'点击打开微信',key_value:parseQueryString('key')?parseQueryString('key'):'',page_name:'推广落地页',url_value:window.location.href,browser:userAgent()})
  484. location.href = 'weixin://dl/business/?t=o3aIVwrmPmt';
  485. _hmt?_hmt.push(['_trackEvent','移动端h5', '点击打开微信', parseQueryString('key')?parseQueryString('key'):'','']):'';
  486. return
  487. }
  488. $("#copyCon").text('问星数据');
  489. var data=document.getElementById("copyCon").innerHTML;
  490. copy_2.innerHTML = data;
  491. copy_1.value = data;
  492. if (navigator.userAgent.match(/(iPhone|iPod|iPad);?/i)) {
  493. //区分iPhone设备
  494. window.getSelection().removeAllRanges();//这段代码必须放在前面否则无效
  495. var Url2=document.getElementById("copy_2");//要复制文字的节点
  496. var range = document.createRange();
  497. // 选中需要复制的节点
  498. range.selectNode(Url2);
  499. // 执行选中元素
  500. window.getSelection().addRange(range);
  501. // 执行 copy 操作
  502. var successful = document.execCommand('copy');
  503. // 移除选中的元素
  504. window.getSelection().removeAllRanges();
  505. }else{
  506. var Url2=document.getElementById("copy_1");//要复制文字的节点
  507. Url2.select(); // 选择对象
  508. document.execCommand("Copy"); // 执行浏览器复制命令
  509. }
  510. showMsg('复制成功!')
  511. burialPoint({project_name:'移动端h5',button_name:'复制成功',key_value:parseQueryString('key')?parseQueryString('key'):'',page_name:'推广落地页',url_value:window.location.href,browser:userAgent()})
  512. _hmt?_hmt.push(['_trackEvent','移动端h5', '复制成功', parseQueryString('key')?parseQueryString('key'):'','']):'';
  513. }
  514. function showMsg(msg) {
  515. var msgBox = $('.alert-info');
  516. msgBox.children('p').text(msg);
  517. msgBox.show();
  518. setTimeout(function() {
  519. msgBox.hide();
  520. }, 1500);
  521. }
  522. </script>