zoukankan      html  css  js  c++  java
  • 博客园的打赏功能

    简单几步为自己的博客园主页添加打赏功能:

    1 准备工作:

    准备支付宝和微信的二维码,后缀名需修改.bmp格式。如zfb.bmp,wx.bmp。

    2 上传图片:

    进入自己的博客园,然后进入 管理--->文件,在这里上传自己第1步中准备好的二维码图片。

    3 复制并根据自己的博客修改如下代码:

    <!DOCTYPE html>
    <html lang="zh-CN">
    <head>
    <meta charset="utf-8" />
    <meta name="keywords" content="打赏" />
    <meta name="description" content="打赏" />
    <title>打赏</title>
    </head>
    <script>
    		window.tctipConfig = {
    			staticPrefix: "http://static.tctip.com",
    			buttonImageId: 5,
    			buttonTip:	"zanzhu",
    			list:{
    				alipay: { qrimg: "https://files.cnblogs.com/files/unnamedprogramer/zfb.bmp"}, //修改1
    				weixin: { qrimg: "https://files.cnblogs.com/files/unnamedprogramer/wx.bmp"}, //修改2
    			}
    		};
    </script>
    <script src="http://static.tctip.com/js/tctip.min.js"></script>
    <body>
    </body>
    </html>
    

    修改1:进入博客,“管理”-->“文件”-->“上传文件管理”-->“文件名”,点击对应的文件名,如博主自己的zfb.bmp这能预览图片,复制图片url,替换上述代码中alipay对应的qrimg参数。
    修改2:同修改1.

    4 将修改后的代码粘贴到指定位置:

    进入博客,找到“管理”-->“设置”,下拉到“首页Html代码”,将上面修改后的代码粘贴进去,点击“保存”。

    5 完成。刷新一下,查看自己的打赏功能吧!!

    最后,感谢https://github.com/greedying/tctip!!

  • 相关阅读:
    Asp.Net Core 2.0 之旅---在Ubuntu上部署WEB应用程序
    xml对象序列化
    txt文本文件记录日志
    HttpGet HttpPost
    c# MD5
    10位时间戳转为C#格式时间
    树莓派上运行.net core 2.0程序
    c# 解析json
    小程序与后台数据交互时出现乱码时
    小程序template怎样渲染页面的
  • 原文地址:https://www.cnblogs.com/unnamedprogramer/p/6186663.html
Copyright © 2011-2022 走看看