forked from TagesschuleElementa/www.tagesschule-elementa.ch
added privacy message
This commit is contained in:
@@ -167,6 +167,30 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="privacy-message" style="display: none;">
|
||||
<div class="privacy-message__frame">
|
||||
<p>
|
||||
{% page_url 'imprint' as privacy_url %}
|
||||
{% blocktrans with privacy_url=privacy_url %}
|
||||
Um diese Webseite optimal gestalten und fortlaufend verbessern zu können, verwenden wir Cookies.
|
||||
Weitere Informationen finden Sie in unserer
|
||||
<a href="{{ privacy_url }}">Datenschutzerklärung im Impressum</a>.
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
<div class="privacy-message__actions">
|
||||
<a href="#" class="button button--small button--ghost privacy_action--decline">
|
||||
<span class="button__icon">{% include 'project/assets/close.svg' %}</span>
|
||||
<span class="button__text">{% trans 'Ablehnen' %}</span>
|
||||
</a>
|
||||
<a href="#" class="button button--small privacy_action--accept">
|
||||
<span class="button__icon">{% include 'project/assets/tick.svg' %}</span>
|
||||
<span class="button__text">{% trans 'Akzeptieren' %}</span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<a href="#" class="privacy-message__close privacy_action--close"></a>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript" src="{% static 'js/lib.js' %}"></script>
|
||||
<script type="text/javascript" src="{% static 'js/main.js' %}"></script>
|
||||
|
||||
@@ -174,5 +198,35 @@
|
||||
|
||||
{% render_block "js" %}
|
||||
{{ ALDRYN_SNAKE.render_tail }}
|
||||
|
||||
<script>
|
||||
$(function() {
|
||||
var init_google_analytics = function() {
|
||||
(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)
|
||||
})(window, document, 'script', 'https://www.google-analytics.com/analytics.js', 'ga');
|
||||
|
||||
ga('create', 'UA-116863155-1', 'auto');
|
||||
ga('set', 'anonymizeIp', true);
|
||||
ga('send', 'pageview');
|
||||
};
|
||||
|
||||
if (window.privacy_accepted) {
|
||||
init_google_analytics();
|
||||
}
|
||||
|
||||
$('body').on('enable_tracking', function() {
|
||||
init_google_analytics();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user