2019-11-04 13:09:44 +00:00
|
|
|
<script>
|
2019-11-24 14:31:28 +00:00
|
|
|
window.onload = function() {
|
2019-12-05 10:04:42 +00:00
|
|
|
// counter
|
|
|
|
{{ $enableBusuanzi := .Site.Params.enableBusuanzi }}
|
|
|
|
var enableBusuanzi = JSON.parse({{ $enableBusuanzi | jsonify }});
|
|
|
|
if (enableBusuanzi) {
|
2020-01-06 16:41:38 +00:00
|
|
|
var sitePvElem = document.querySelector('#busuanzi_value_site_pv');
|
|
|
|
var siteUvElem = document.querySelector('#busuanzi_value_site_uv');
|
|
|
|
sitePvElem.textContent = sitePvElem.textContent.replace(/(\d)(?=(\d\d\d)+(?!\d))/g, "$1,");
|
|
|
|
siteUvElem.textContent = siteUvElem.textContent.replace(/(\d)(?=(\d\d\d)+(?!\d))/g, "$1,");
|
2019-12-08 14:29:02 +00:00
|
|
|
}
|
2019-11-24 14:31:28 +00:00
|
|
|
}
|
|
|
|
</script>
|