diff --git a/mpicms/base/templatetags/base_tags.py b/mpicms/base/templatetags/base_tags.py index a2bc401..0286963 100644 --- a/mpicms/base/templatetags/base_tags.py +++ b/mpicms/base/templatetags/base_tags.py @@ -18,4 +18,11 @@ def is_subscribed(page, user): @register.simple_tag def room_link(room): - return get_room_link(room) \ No newline at end of file + return get_room_link(room) + + +@register.filter +def remove_i18n(url): + if url.startswith('/en') or url.startswith('/de'): + return url[3:] + return url diff --git a/mpicms/templates/menus/main.html b/mpicms/templates/menus/main.html index ff2516e..cf1fa79 100644 --- a/mpicms/templates/menus/main.html +++ b/mpicms/templates/menus/main.html @@ -1,4 +1,4 @@ -{% load static i18n wagtailcore_tags %} +{% load static i18n wagtailcore_tags base_tags %} {% get_current_language as LANGUAGE_CODE %} @@ -37,6 +37,7 @@ {% else %}
{% csrf_token %} +