GA/UserVoice opt-in
This commit is contained in:
@@ -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 .
|
||||
```
|
||||
|
21239
bindata_gen.go
21239
bindata_gen.go
File diff suppressed because one or more lines are too long
@@ -25,6 +25,8 @@
|
||||
|
||||
<body id="download">
|
||||
<script>
|
||||
var gaKey = "{{.GAKey}}";
|
||||
if (gaKey != "") {
|
||||
(function (i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function () {
|
||||
@@ -36,8 +38,9 @@
|
||||
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>
|
||||
|
||||
<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,6 +108,8 @@
|
||||
<![endif]-->
|
||||
|
||||
<script>
|
||||
var gaKey = "{{.GAKey}}";
|
||||
if (gaKey != "") {
|
||||
(function(b, o, i, l, e, r) {
|
||||
b.GoogleAnalyticsObject = l;
|
||||
b[l] || (b[l] =
|
||||
@@ -114,8 +122,9 @@
|
||||
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('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,4 +1,6 @@
|
||||
<script>
|
||||
var gaKey = "{{.GAKey}}";
|
||||
if (gaKey != "") {
|
||||
(function(i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function() {
|
||||
@@ -10,6 +12,7 @@
|
||||
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>
|
||||
|
@@ -12,6 +12,8 @@ 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 () {
|
||||
@@ -23,8 +25,9 @@ include "includes/head.html"
|
||||
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
Reference in New Issue
Block a user