首先注册一个“百度統計”账号(注册地址:http://tongji.baidu.com/web/welcome/login),获取 访问分析代码。

 

然后找到footer.php文件,在wp-content/themes/xx/目录下(xx是你的主题文件),把生成的统计代码放到 </body>前面。如下:

……

<script type=”text/javascript”>
var _bdhmProtocol = ((“https:” == document.location.protocol) ? ” https://” : ” http://”);
document.write(unescape(“%3Cscript src=’” + _bdhmProtocol + “hm.baidu.com/h.js%3F40c495f41659bd8e887′ type=’text/javascript’%3E%3C/script%3E”));
</script>


</body> (放到这个标签前面即可)
</html>

修改后更新文件,到统计后台检查代码安装情况,系统会告诉是否安装成功。

相关文章:

  • 2021-09-02
  • 2022-01-15
  • 2021-10-11
  • 2021-12-25
  • 2021-08-27
  • 2021-12-06
  • 2021-08-09
猜你喜欢
  • 2022-01-29
  • 2022-01-02
  • 2021-12-06
  • 2021-09-01
相关资源
相似解决方案