<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>月租续费</title>
<meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=0">
<style>
.subscribe-btn {
color: #fff;
background-color: #07c160;
}
</style>
<script src="https://res.wx.qq.com/open/js/jweixin-1.6.0.js"></script>
<script>
document.addEventListener('WeixinOpenTagsError', function (e) {
console.error(e); // 无法使用开放标签的错误原因,需回退兼容。仅无法使用开放标签,JS-SDK其他功能不受影响
});
wx.config({
debug: true, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
appId: '${appId}', // 必填,服务号的唯一标识
timestamp: '${timestamp}', // 必填,生成签名的时间戳
nonceStr: '${nonceStr}', // 必填,生成签名的随机串
signature: '${signature}',// 必填,签名
jsApiList: ['getNetworkType'], // 必填,需要使用的JS接口列表
openTagList: ['wx-open-subscribe']
});
</script>
</head>
<body>
<button class="subscribe-btn" id="btn1">
JSSDK按钮
</button>
<wx-open-subscribe template="Q06f_Eo2OhHk1FPAphO9gF-S2_gqLe2GgYoLIROOPP8" id="subscribe-btn">
<script type="text/wxtag-template" slot="style">
<style>
.subscribe-btn {
color: #fff;
background-color: #07c160;
}
</style>
</script>
<script type="text/wxtag-template">
<button class="subscribe-btn">
一次性模版消息订阅
</button>
</script>
</wx-open-subscribe>
<script>
var btn = document.getElementById('subscribe-btn');
btn.addEventListener('success', function (e) {
console.log('success', e.detail);
});
btn.addEventListener('error',function (e) {
console.log('fail', e.detail);
});
wx.ready(function(e){
console.log("加载成功",e);
});
var btn1 = document.getElementById('btn1');
btn1.addEventListener('click', function (e) {
wx.getNetworkType({
success: function (res) {
}
});
});
</script>
</body>
</html>
----------------------------------------------------------------------
btn1可以正常调用jssdk说明config配置没问题
subscribe-btn页面无显示

你好,控制台打印下config参数和其他相关参数
config后的ready和error打印下啊根据手册和流程都排查过了
1、域名肯定配置了,因为调用jssdk的其他jsapi是可以正常打印
2、模板id是直接在服务号订阅消息的生效的列表中复制的
3、document.querySelector('wx-open-subscribe')控制台可以取到dom元素,未设置元素或父级元素隐藏
4、代理中的WeixinOpenTagsError确定在wx.config之前执行
5、开发者工具和微信电脑端及微信手机端都试了没有显示
6、访问地址https://gateway.park118.com/btx-dev/qrcode/premon.jsp?pn=0002