Adds google analytics to the docs that will go on akka.io.
This commit is contained in:
parent
4e22b88410
commit
d4f565fb30
2 changed files with 14 additions and 0 deletions
|
|
@ -11,6 +11,7 @@
|
||||||
{% set script_files = script_files + ['_static/effects.highlight.js'] %}
|
{% set script_files = script_files + ['_static/effects.highlight.js'] %}
|
||||||
{% set script_files = script_files + ['_static/scrollTo.js'] %}
|
{% set script_files = script_files + ['_static/scrollTo.js'] %}
|
||||||
{% set script_files = script_files + ['_static/contentsFix.js'] %}
|
{% set script_files = script_files + ['_static/contentsFix.js'] %}
|
||||||
|
{% set script_files = script_files + ['_static/ga.js'] %}
|
||||||
{% set css_files = css_files + ['_static/prettify.css'] %}
|
{% set css_files = css_files + ['_static/prettify.css'] %}
|
||||||
{% set css_files = css_files + ['_static/base.css'] %}
|
{% set css_files = css_files + ['_static/base.css'] %}
|
||||||
{% set css_files = css_files + ['_static/docs.css'] %}
|
{% set css_files = css_files + ['_static/docs.css'] %}
|
||||||
|
|
|
||||||
13
akka-docs/_sphinx/themes/akka/static/ga.js
Normal file
13
akka-docs/_sphinx/themes/akka/static/ga.js
Normal file
|
|
@ -0,0 +1,13 @@
|
||||||
|
// check to see if this document is on the akka.io server. If so, google analytics.
|
||||||
|
if (/akka\.io/.test(document.domain)) {
|
||||||
|
var _gaq = _gaq || [];
|
||||||
|
_gaq.push(['_setAccount', 'UA-21117439-1']);
|
||||||
|
_gaq.push(['_setDomainName', 'akka.io']);
|
||||||
|
_gaq.push(['_trackPageview']);
|
||||||
|
|
||||||
|
(function() {
|
||||||
|
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
|
||||||
|
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
|
||||||
|
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
|
||||||
|
})();
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue