<?php if($launchApp): ?> <wx-open-launch-app id="launch-btn" appid="有ID" extinfo="<?= $copyData?>"> <script type="text/wxtag-template"> <?php endif; ?> <style> .open_btn{ display: block; width: 80px; height: 32px; line-height: 32px; text-align: center; color: #fff; font-size: 14px; border-radius: 4px; background-color: #e8554d; outline:0; border:0; } </style> <button class="open_btn" <?= $launchApp ? '' : 'data-js="openClient"'?>>打开</button> <?php if($launchApp):?> </script> </wx-open-launch-app> <?php endif; ?> 微信JSSDK 也有 也注册了微信开放标签 但就是不显示
不显示<wx-open-launch-app>的按钮?这是安卓[图片],这是苹果[图片]。样式问题先不管,跳转的按钮你得给我显示啊。正常平铺下来不添加父级和定位,跳转按钮是可以正常显示,但是在添加父级盒子及定位后安卓的就不显示了,有谁知道是什么问题吗?
2022-03-22我的也是按钮不显示 我都调了三天三夜了
wx-open-launch-app 按钮内容不显示?测试地址:https://dict.eudic.net/Courses/index/?appkey=eusoft_ting_en_iphone&courseId=f108a92f-f050-48b2-8f59-f3cc05fac17a&sourcefrom=share 微信版本:8.0.2 设备:iphone11 运行结果:wx.ready运行成功,wx.error也没有报错。但是打开按钮就是不显示 [图片] 公众号appid:wxcde3c24f7569ba13 移动应用appid:wx3d9bc15510620bf2 这些条件都是满足的 [图片][图片] 但是debug显示为false [图片][图片] 代码: <wx-open-launch-app id="launch-btn" appid="wx3d9bc15510620bf2" extinfo=""> <template> <style> .btn { width: 70px; height: 30px; line-height: 30px; text-align: center; font-size: 15px; color: rgb(49, 149, 252); border-radius:50px; border: 2px solid rgba(49,149,252,0.50); } </style> <button class="btn">打开</button> </template> </wx-open-launch-app> $.ajax({ url: "/ting/WeChatSignatureUrl?url=" +encodeURIComponent(window.location.href), type: "GET", dataType: 'json', success: function (data) { var param=data; configParam(param); }, error: function (err) { console.log("err: " + err) } }); function configParam(param) { console.log(param) wx.config({ debug: true, appId: param.AppId, timestamp: param.Timestamp, nonceStr: param.Noncestr, signature: param.Signature, jsApiList: ['checkJsApi'], openTagList: ['wx-open-launch-app'] }); wx.ready(function () { wx.checkJsApi({ jsApiList: ['wx-open-launch-app'], success: function (res) { console.log('可用') }, fail: (err) => { console.log(err, '不可用') } }) }); wx.error(function (res) { console.log(res) }); } var launchBtn = document.getElementById('launch-btn'); if (launchBtn) { launchBtn.addEventListener('launch', function (e) { console.log('success'); }); launchBtn.addEventListener('error', function (e) { console.log('fail', e.detail); }); }
2022-03-22