Skip to content

Commit 6396c44

Browse files
committed
baidu
1 parent 74f9b37 commit 6396c44

File tree

3 files changed

+4
-17
lines changed

3 files changed

+4
-17
lines changed

_config.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ disqus:
3434

3535
# Enter your Google Analytics web tracking code (e.g. UA-2110908-2) to activate tracking
3636
google_analytics:
37-
37+
baidu_analytics: true
3838
# Your website URL (e.g. http://barryclark.github.io or http://www.barryclark.co)
3939
# Used for Sitemap.xml and your RSS feed
4040
url: http://www.labazhou.net

_includes/analytics.html

+2-15
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,3 @@
1-
{% if site.google_analytics %}
2-
<!-- Google Analytics -->
3-
<script type="text/javascript">
4-
5-
var _gaq = _gaq || [];
6-
_gaq.push(['_setAccount', '{{ site.google_analytics }}']);
7-
_gaq.push(['_trackPageview']);
8-
9-
(function() {
10-
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
11-
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
12-
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
13-
})();
14-
15-
</script>
1+
{% if site.baidu_analytics %}
2+
<script type="text/javascript">var cnzz_protocol = (("https:" == document.location.protocol) ? " https://" : " http://");document.write(unescape("%3Cspan id='cnzz_stat_icon_1261194409'%3E%3C/span%3E%3Cscript src='" + cnzz_protocol + "s11.cnzz.com/z_stat.php%3Fid%3D1261194409' type='text/javascript'%3E%3C/script%3E"));</script>
163
{% endif %}

_layouts/default.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
{{ content }}
4444

4545
</body>
46-
46+
{% include analytics.html %}
4747
</html>
4848

4949

0 commit comments

Comments
 (0)