微信公众号页面提醒关注悬浮框

chen'mo
2021-03-17 / 0 评论 / 5,910 阅读 / 正在检测是否收录...
温馨提示:
本文最后更新于2021年03月15日,已超过1462天没有更新,若内容或图片失效,请留言反馈。

简单来说就是给网页右下角加个弹窗,显示公众号二维码,需要引入layui

<!--微信关注提醒 start-->
    <!-- {if !get_subscribe($user['id'])}-->
    <button class="guide" onclick="follow_wx()">关注公众号</button>
    <style type="text/css">
    .guide{width:20px;height:100px;text-align: center;border-radius: 8px ;font-size:12px;padding:8px 0;border:1px solid #adadab;color:#000000;background-color: #fff;position: fixed;right: 6px;bottom: 200px;}
    #cover{display:none;position:absolute;left:0;top:0;z-index:18888;background-color:#000000;opacity:0.7;}
    #guide{display:none;position:absolute;top:5px;z-index:19999;}
    #guide img{width: 70%;height: auto;display: block;margin: 0 auto;margin-top: 10px;}
    </style>
    <script type="text/javascript">
    // 关注微信公众号二维码
    function follow_wx()
    {
        layer.open({
            type : 1,
            title: '关注公众号',
            content: '<img src="__ROOT__/wx/images/qrcode.jpg" width="200">',
            style: ''
        });
    }
    </script>
    <!--{/if} -->
<!--微信关注提醒  end-->
0
那一年 · 3月17日
WxFans 一款 typecho 微信公账号涨粉插件,支持动态验证码
« 上一篇 03-16
使用代码为网页顶部加上加载进度条
下一篇 » 03-19

评论 (0)