Merge pull request #10 from dutchcoders/GA-UserVoice-opt-in
GA/UserVoice opt-in
This commit is contained in:
commit
fca3a071d7
|
@ -5,6 +5,8 @@ This repository contains the web frontend for [transfer.sh](github.com/dutchcode
|
|||
## Build
|
||||
|
||||
```
|
||||
$ go get -u github.com/shuLhan/go-bindata/...
|
||||
$ bower install
|
||||
$ grunt build
|
||||
$ go generate .
|
||||
```
|
||||
|
|
21247
bindata_gen.go
21247
bindata_gen.go
File diff suppressed because one or more lines are too long
|
@ -25,19 +25,22 @@
|
|||
|
||||
<body id="download">
|
||||
<script>
|
||||
(function(i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function() {
|
||||
var gaKey = "{{.GAKey}}";
|
||||
if (gaKey != "") {
|
||||
(function (i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function () {
|
||||
(i[r].q = i[r].q || []).push(arguments)
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
m = s.getElementsByTagName(o)[0];
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
ga('create', 'UA-40833733-1', 'transfer.sh');
|
||||
ga('send', 'pageview');
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
ga('create', gaKey, 'transfer.sh');
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
</script>
|
||||
|
||||
<div id="navigation">
|
||||
|
@ -88,12 +91,15 @@
|
|||
|
||||
<script>
|
||||
(function() {
|
||||
var userVoiceKey = "{{.UserVoiceKey}}";
|
||||
if (userVoiceKey != "") {
|
||||
var uv = document.createElement('script');
|
||||
uv.type = 'text/javascript';
|
||||
uv.async = true;
|
||||
uv.src = '//widget.uservoice.com/5rkATbLIm8ClJQeOirOhFg.js';
|
||||
uv.src = '//widget.uservoice.com/{{.UserVoiceKey}}.js';
|
||||
var s = document.getElementsByTagName('script')[0];
|
||||
s.parentNode.insertBefore(uv, s)
|
||||
s.parentNode.insertBefore(uv, s);
|
||||
}
|
||||
})()
|
||||
</script>
|
||||
|
||||
|
@ -102,20 +108,23 @@
|
|||
<![endif]-->
|
||||
|
||||
<script>
|
||||
(function(b, o, i, l, e, r) {
|
||||
b.GoogleAnalyticsObject = l;
|
||||
b[l] || (b[l] =
|
||||
var gaKey = "{{.GAKey}}";
|
||||
if (gaKey != "") {
|
||||
(function(b, o, i, l, e, r) {
|
||||
b.GoogleAnalyticsObject = l;
|
||||
b[l] || (b[l] =
|
||||
function() {
|
||||
(b[l].q = b[l].q || []).push(arguments)
|
||||
(b[l].q = b[l].q || []).push(arguments)
|
||||
});
|
||||
b[l].l = +new Date;
|
||||
e = o.createElement(i);
|
||||
r = o.getElementsByTagName(i)[0];
|
||||
e.src = '//www.google-analytics.com/analytics.js';
|
||||
r.parentNode.insertBefore(e, r)
|
||||
}(window, document, 'script', 'ga'));
|
||||
ga('create', 'UA-40833733-1', 'transfer.sh');
|
||||
ga('send', 'pageview');
|
||||
b[l].l = +new Date;
|
||||
e = o.createElement(i);
|
||||
r = o.getElementsByTagName(i)[0];
|
||||
e.src = '//www.google-analytics.com/analytics.js';
|
||||
r.parentNode.insertBefore(e, r)
|
||||
}(window, document, 'script', 'ga'));
|
||||
ga('create', gaKey, 'transfer.sh');
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
</script>
|
||||
|
||||
<!-- build:js scripts/main.js -->
|
||||
|
|
|
@ -20,12 +20,15 @@
|
|||
|
||||
<script>
|
||||
(function() {
|
||||
var userVoiceKey = "{{.UserVoiceKey}}";
|
||||
if (userVoiceKey != "") {
|
||||
var uv = document.createElement('script');
|
||||
uv.type = 'text/javascript';
|
||||
uv.async = true;
|
||||
uv.src = '//widget.uservoice.com/5rkATbLIm8ClJQeOirOhFg.js';
|
||||
uv.src = '//widget.uservoice.com/{{.UserVoiceKey}}.js';
|
||||
var s = document.getElementsByTagName('script')[0];
|
||||
s.parentNode.insertBefore(uv, s)
|
||||
}
|
||||
})()
|
||||
</script>
|
||||
|
||||
|
|
|
@ -1,15 +1,18 @@
|
|||
<script>
|
||||
(function(i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function() {
|
||||
var gaKey = "{{.GAKey}}";
|
||||
if (gaKey != "") {
|
||||
(function(i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function() {
|
||||
(i[r].q = i[r].q || []).push(arguments)
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
m = s.getElementsByTagName(o)[0];
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
ga('create', 'UA-40833733-1', 'transfer.sh');
|
||||
ga('send', 'pageview');
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
ga('create', gaKey, 'transfer.sh');
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
</script>
|
||||
|
|
|
@ -12,19 +12,22 @@ include "includes/head.html"
|
|||
<body>
|
||||
|
||||
<script>
|
||||
var gaKey = "{{.GAKey}}";
|
||||
if (gaKey != "") {
|
||||
(function (i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function () {
|
||||
(i[r].q = i[r].q || []).push(arguments)
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
m = s.getElementsByTagName(o)[0];
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function () {
|
||||
(i[r].q = i[r].q || []).push(arguments)
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
m = s.getElementsByTagName(o)[0];
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
ga('create', 'UA-40833733-1', 'transfer.sh');
|
||||
ga('create', gaKey, 'transfer.sh');
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
</script>
|
||||
|
||||
include "includes/navigation.html"
|
||||
|
|
4309
src/styles/main.css
4309
src/styles/main.css
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue