# HG changeset patch # User Dennis Fink # Date 2015-10-13 19:55:54 # Node ID d6232077c9297fd1253c4a689c4c03915edd04fb # Parent d5952273ec1e41d7e1e336f73f31c0c5811e64bc Use alternative addresses for wiki and globe if connecting to the hidden service diff --git a/ennstatus/templates/base.html b/ennstatus/templates/base.html --- a/ennstatus/templates/base.html +++ b/ennstatus/templates/base.html @@ -52,7 +52,7 @@
  • Mirrors
  • -
  • Wiki
  • +
  • Wiki
  • About Ennstatus
  • diff --git a/ennstatus/templates/macros.html b/ennstatus/templates/macros.html --- a/ennstatus/templates/macros.html +++ b/ennstatus/templates/macros.html @@ -16,3 +16,13 @@ {{ message }} {% endmacro %} + +{% macro get_wiki_address() %} + {% if '.onion' in request.url_root %} + {{ config['ENNSTATUS_WIKI_ONION_ADDRESS'] }} + {% elif '.bit' in request.url_root %} + {{ config['ENNSTATUS_WIKI_BIT_ADDRESS'] }} + {% else %} + //wiki.enn.lu + {% endif %} +{% endmacro %} diff --git a/ennstatus/templates/root/mirrors.html b/ennstatus/templates/root/mirrors.html --- a/ennstatus/templates/root/mirrors.html +++ b/ennstatus/templates/root/mirrors.html @@ -2,6 +2,16 @@ {% set title = "Partners" %} +{% macro get_globe_address() %} + {% if '.onion' in request.url_root %} + {{ config['ENNSTATUS_GLOBE_ONION_ADDRESS'] }} + {% elif '.bit' in request.url_root %} + {{ config['ENNSTATUS_GLOBE_BIT_ADDRESS'] }} + {% else %} + //globe.enn.lu + {% endif %} +{% endmacro %} + {% block content %}
    Partners @@ -17,7 +27,7 @@
    tails.enn.lu
    A Tails Download mirror. Tails is a live operating system, that you can start on almost any computer from a DVD, USB stick, or SD card. It aims at preserving your privacy and anonymity. Learn more about Tails

    -
    globe.enn.lu
    +
    globe.enn.lu
    Globe is a Tor relay and bridge explorer.