Skip to content

Commit

Permalink
Removed page_view event
Browse files Browse the repository at this point in the history
  • Loading branch information
desafinadude committed Oct 19, 2023
1 parent bbc433b commit 25821bb
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion pmg/templates/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,23 @@
})(window,document,'script','dataLayer','{{ config['GOOGLE_ANALYTICS_ID'] }}');</script>
<!-- End Google Tag Manager -->

<script async src="https://www.googletagmanager.com/gtag/js?id={{ config['GOOGLE_ANALYTICS_ID'] }}"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());

gtag('config', '{{ config['GOOGLE_ANALYTICS_ID'] }}');
</script>


<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="csrf-token" content="{{ csrf_token() }}">
<title>{% block title %}Parliamentary Monitoring Group | South Africa{% endblock %}</title>



<!--
DON'T SCRAPE, USE THE API! :)
Expand Down Expand Up @@ -102,7 +114,6 @@
gtag('set', {'dimension4': '{{ via_tag }}'});
{% endif %}

gtag('event', 'page_view');

{% for cat, action, label, value in get_ga_events() %}
gtag('event', '{{ action }}', { 'event_category': '{{ cat }}'
Expand Down

0 comments on commit 25821bb

Please sign in to comment.