aboutsummaryrefslogtreecommitdiffstats
path: root/fatcat_scholar/templates/base.html
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@archive.org>2020-10-22 14:02:47 -0700
committerBryan Newbold <bnewbold@archive.org>2020-10-22 14:05:28 -0700
commit979bd469d62ffb0ad53391a31aa789978ce1d6b8 (patch)
tree1f05d73690c5ec8fb1f6b0d361b4af9fe8379b51 /fatcat_scholar/templates/base.html
parentaaa96e932fb365026a6c7646aabc98a95f48319e (diff)
downloadfatcat-scholar-979bd469d62ffb0ad53391a31aa789978ce1d6b8.tar.gz
fatcat-scholar-979bd469d62ffb0ad53391a31aa789978ce1d6b8.zip
integrate goatcounter JS (analytics)
Diffstat (limited to 'fatcat_scholar/templates/base.html')
-rw-r--r--fatcat_scholar/templates/base.html4
1 files changed, 4 insertions, 0 deletions
diff --git a/fatcat_scholar/templates/base.html b/fatcat_scholar/templates/base.html
index 079b298..6302f6f 100644
--- a/fatcat_scholar/templates/base.html
+++ b/fatcat_scholar/templates/base.html
@@ -276,6 +276,10 @@ document.getElementById("search_form").onsubmit = function(){
document.getElementById("search_submit_button").classList.add("loading");
};
</script>
+{% if settings.ENABLE_GOATCOUNTER -%}
+ {# for local testing: <script>window.goatcounter = {allow_local: true};</script> #}
+ <script data-goatcounter="{{ settings.GOATCOUNTER_ENDPOINT }}" async src="{{ settings.GOATCOUNTER_SCRIPT_URL }}"></script>
+{%- endif %}
{% block postscript %}{% endblock %}
</body>
</html>