Loading... ## 博客运行时间 为博客添加运行时间,效果如图所示:  具体[实现代码](http://www.52xybk.top/post/2)如下,将该段代码加入到`footer.html`里面即可。 ```javascript <center> 露水已存留 <SPAN id=span_dt_dt style="color: #0196e3;"></SPAN> //名字自己修改 <SCRIPT language=javascript> function show_date_time(){ window.setTimeout("show_date_time()", 1000); BirthDay=new Date("9/13/2018 00:00:00");//日期自己修改 today=new Date(); timeold=(today.getTime()-BirthDay.getTime()); sectimeold=timeold/1000 secondsold=Math.floor(sectimeold); msPerDay=24*60*60*1000 e_daysold=timeold/msPerDay daysold=Math.floor(e_daysold); e_hrsold=(e_daysold-daysold)*24; hrsold=Math.floor(e_hrsold); e_minsold=(e_hrsold-hrsold)*60; minsold=Math.floor((e_hrsold-hrsold)*60); seconds=Math.floor((e_minsold-minsold)*60); span_dt_dt.innerHTML=""+daysold+"天"+hrsold+"小时"+minsold+"分"+seconds+"秒"; } show_date_time(); </SCRIPT> </center> ``` ## 利用[不蒜子](http://busuanzi.ibruce.info/)增加阅读量统计 **感谢[不蒜子](https://busuanzi.ibruce.info/)提供的免费服务** ### 安装脚本 ```html <script async src="//busuanzi.ibruce.info/busuanzi/2.3/busuanzi.pure.mini.js"></script> ``` 该脚本文件同样添加到`footer.html`中,如图  ### 安装标签 * 网站访问量  代码如下: ```html <span id="busuanzi_container_site_uv"> 您是本站第<span id="busuanzi_value_site_uv"></span>位小伙伴 </span> ``` 写在 `footer.html`中,位置如图,里面的文字可以自己修改。  * 单页面访问次数  代码如下,出自[LingLinyp的`Github`](https://github.com/LingLinyp/LingLinyp.github.io) ```html <span class="meta"><i class="fa fa-user" aria-hidden="true"></i> {% if site.author %}{{ site.author }}{% else %}{{ site.title }}{% endif %} <i class="fa fa-calendar" aria-hidden="true"></i> {{ page.date | date: "%Y-%m-%d" }} <i class="fa fa-check-square-o" aria-hidden="true"></i>{{ content | strip_html | strip_newlines | size }} words <span id="busuanzi_container_page_pv"> <i class="fa fa-eye" aria-hidden="true"></i> <span id="busuanzi_value_page_pv">&</span> views</span> ``` 该段代码写在 `post.html`中,位置如图:  最后修改:2021 年 06 月 10 日 © 允许规范转载 赞 0 如果觉得我的文章对你有用,请随意赞赏