Add TRACKING_ID in optOut URL as well, move Privacy setting in before Logout in header
authorSimon Descarpentries <sid@sopinspace.com>
Tue, 06 May 2014 15:55:24 +0200
changeset 652 2484db74c150
parent 651 9bbc657f6837
child 653 f32c9dcb04e1
Add TRACKING_ID in optOut URL as well, move Privacy setting in before Logout in header
src/cm/templates/site/layout/header.html
src/cm/templates/site/tracking.html
--- a/src/cm/templates/site/layout/header.html	Tue May 06 13:52:01 2014 +0200
+++ b/src/cm/templates/site/layout/header.html	Tue May 06 15:55:24 2014 +0200
@@ -4,9 +4,6 @@
 
 <div id="header_controls">
 
-{% if not DISABLE_TRACKING %}
-   <a id="hide-piwik-cookies-optout">{% blocktrans %}Privacy policy{% endblocktrans %} ▼ </a> ·
-{% endif %}
 {% if user.is_authenticated %}<b>{{ user.username }}</b> ·{% endif %} 
    <a title="{% blocktrans %}Home{% endblocktrans %}" href="{% url index %}">{% blocktrans %}Home{% endblocktrans %}</a>
    {% if can_create_text %}    
@@ -16,6 +13,9 @@
    {% endif %}
 {% if user.is_authenticated %}
  · <a title="{% blocktrans %}Profile{% endblocktrans %}" href="{% url profile %}">{% blocktrans %}Profile{% endblocktrans %}</a>
+{% if TRACKING_ID %}
+ ·  <a id="hide-piwik-cookies-optout">{% blocktrans %}Privacy policy{% endblocktrans %} </a> 
+{% endif %}
  · <a title="{% blocktrans %}Logout{% endblocktrans %}" href="{% url logout %}">{% blocktrans %}Logout{% endblocktrans %}</a>
 {% else%} 
  · <a title="{% blocktrans %}Login{% endblocktrans %}" href="{% url login %}">{% blocktrans %}Login{% endblocktrans %}</a>
--- a/src/cm/templates/site/tracking.html	Tue May 06 13:52:01 2014 +0200
+++ b/src/cm/templates/site/tracking.html	Tue May 06 15:55:24 2014 +0200
@@ -35,5 +35,5 @@
 });
 -->
 </script>
-<div id="piwik-cookies-optout"><iframe frameborder="no" width="900px" height="90px" src="https://stats.co-ment.com/index.php?module=CustomOptOut&action=optOut&idSite=17&language={{ LANGUAGE_CODE }}"></iframe></div>
+<div id="piwik-cookies-optout"><iframe frameborder="no" width="900px" height="90px" src="https://stats.co-ment.com/index.php?module=CustomOptOut&action=optOut&idSite={{ TRACKING_ID }}&language={{ LANGUAGE_CODE }}"></iframe></div>
 {% endif %}