diff options
Diffstat (limited to 'tpl/tplimpl')
-rw-r--r-- | tpl/tplimpl/embedded/templates.autogen.go | 2 | ||||
-rwxr-xr-x | tpl/tplimpl/embedded/templates/google_analytics.html | 1 | ||||
-rwxr-xr-x | tpl/tplimpl/embedded/templates/google_analytics_async.html | 1 |
3 files changed, 4 insertions, 0 deletions
diff --git a/tpl/tplimpl/embedded/templates.autogen.go b/tpl/tplimpl/embedded/templates.autogen.go index 9b4db35d6..9637deb10 100644 --- a/tpl/tplimpl/embedded/templates.autogen.go +++ b/tpl/tplimpl/embedded/templates.autogen.go @@ -111,6 +111,7 @@ if (!doNotTrack) { })(window,document,'script','https://www.google-analytics.com/analytics.js','ga'); ga('create', '{{ . }}', 'auto'); ga('send', 'pageview'); + {{ if $pc.AnonymizeIP }}ga('set', 'anonymizeIp', true);{{ end -}} } </script> {{ end }} @@ -133,6 +134,7 @@ if (!doNotTrack) { window.ga=window.ga||function(){(ga.q=ga.q||[]).push(arguments)};ga.l=+new Date; ga('create', '{{ . }}', 'auto'); ga('send', 'pageview'); + {{ if $pc.AnonymizeIP }}ga('set', 'anonymizeIp', true);{{ end -}} } </script> <script async src='//www.google-analytics.com/analytics.js'></script> diff --git a/tpl/tplimpl/embedded/templates/google_analytics.html b/tpl/tplimpl/embedded/templates/google_analytics.html index ae4898c7a..611c1c726 100755 --- a/tpl/tplimpl/embedded/templates/google_analytics.html +++ b/tpl/tplimpl/embedded/templates/google_analytics.html @@ -10,6 +10,7 @@ if (!doNotTrack) { })(window,document,'script','https://www.google-analytics.com/analytics.js','ga'); ga('create', '{{ . }}', 'auto'); ga('send', 'pageview'); + {{ if $pc.AnonymizeIP }}ga('set', 'anonymizeIp', true);{{ end -}} } </script> {{ end }} diff --git a/tpl/tplimpl/embedded/templates/google_analytics_async.html b/tpl/tplimpl/embedded/templates/google_analytics_async.html index b81ade025..18e18a168 100755 --- a/tpl/tplimpl/embedded/templates/google_analytics_async.html +++ b/tpl/tplimpl/embedded/templates/google_analytics_async.html @@ -7,6 +7,7 @@ if (!doNotTrack) { window.ga=window.ga||function(){(ga.q=ga.q||[]).push(arguments)};ga.l=+new Date; ga('create', '{{ . }}', 'auto'); ga('send', 'pageview'); + {{ if $pc.AnonymizeIP }}ga('set', 'anonymizeIp', true);{{ end -}} } </script> <script async src='//www.google-analytics.com/analytics.js'></script> |