src/hdalab/templates/google_analytics/analytics_template.html
author cavaliet
Tue, 17 Jun 2014 10:25:33 +0200
changeset 271 8f77cf71ab02
parent 170 web/hdalab/templates/google_analytics/analytics_template.html@cb3e869ab252
child 627 3fd558fa38b1
permissions -rw-r--r--
commit the venv update (django and dependancies) in the good head
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
170
cb3e869ab252 Add google analytics
ymh <ymh.work@gmail.com>
parents:
diff changeset
     1
<script type="text/javascript">
cb3e869ab252 Add google analytics
ymh <ymh.work@gmail.com>
parents:
diff changeset
     2
var _gaq = _gaq || [];
cb3e869ab252 Add google analytics
ymh <ymh.work@gmail.com>
parents:
diff changeset
     3
_gaq.push(['_setAccount', '{{ analytics_code }}']);
cb3e869ab252 Add google analytics
ymh <ymh.work@gmail.com>
parents:
diff changeset
     4
_gaq.push(['_trackPageview']);
cb3e869ab252 Add google analytics
ymh <ymh.work@gmail.com>
parents:
diff changeset
     5
(function() {
cb3e869ab252 Add google analytics
ymh <ymh.work@gmail.com>
parents:
diff changeset
     6
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
cb3e869ab252 Add google analytics
ymh <ymh.work@gmail.com>
parents:
diff changeset
     7
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
cb3e869ab252 Add google analytics
ymh <ymh.work@gmail.com>
parents:
diff changeset
     8
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
cb3e869ab252 Add google analytics
ymh <ymh.work@gmail.com>
parents:
diff changeset
     9
})();
cb3e869ab252 Add google analytics
ymh <ymh.work@gmail.com>
parents:
diff changeset
    10
</script>