Skip to content

Commit

Permalink
fixup analytics (pytorch#1504)
Browse files Browse the repository at this point in the history
Co-authored-by: Brian Johnson <brianjo@fb.com>
  • Loading branch information
Randall Hunt and brianjo authored May 4, 2021
1 parent e24dced commit 0244815
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 20 deletions.
20 changes: 0 additions & 20 deletions _templates/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,6 @@

{% block footer %}
{{ super() }}
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-117752657-2"></script>

<script>

window.dataLayer = window.dataLayer || [];

function gtag(){dataLayer.push(arguments);}

gtag('js', new Date());
gtag('config', 'UA-117752657-2');

</script>

<script>
!function(f,b,e,v,n,t,s)
{if(f.fbq)return;n=f.fbq=function(){n.callMethod?
Expand All @@ -34,13 +21,6 @@
tutorialLink: window.location.href,
downloadTitle: $(this).attr("data-response")
});
ga('send', {
hitType: 'event',
eventCategory: $(this).attr("data-response"),
eventAction: 'click',
eventLabel: window.location.href
});

gtag('event', 'click', {
'event_category': $(this).attr("data-response"),
'event_label': $("h1").first().text(),
Expand Down
1 change: 1 addition & 0 deletions conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,7 @@
'collapse_navigation': False,
'display_version': True,
'logo_only': False,
'analytics_id': 'UA-117752657-2',
}


Expand Down

0 comments on commit 0244815

Please sign in to comment.