forked from boyska/sito-hackit-16
Localized menu, finally
This commit is contained in:
parent
102fde3931
commit
d202c0260c
1 changed files with 6 additions and 8 deletions
|
@ -211,16 +211,14 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="collapse navbar-collapse navbar-ex1-collapse">
|
<div class="collapse navbar-collapse navbar-ex1-collapse">
|
||||||
<ul class="nav navbar-nav">
|
<ul class="nav navbar-nav">
|
||||||
{% for title, link in MENUITEMS %}
|
{% if page %}
|
||||||
|
{% set menu = LOCALMENUITEMS[page.lang] %}
|
||||||
|
{% else %}
|
||||||
|
{% set menu = MENUITEMS %}
|
||||||
|
{% endif %}
|
||||||
|
{% for title, link in menu %}
|
||||||
<li><a href="{{ link }}">{{ title }}</a></li>
|
<li><a href="{{ link }}">{{ title }}</a></li>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
{% if DISPLAY_PAGES_ON_MENU %}
|
|
||||||
{% for p in PAGES %}
|
|
||||||
<li{% if p == page %} class="active"{% endif %}><a href="{{ SITEURL }}/{{ p.url }}">
|
|
||||||
{{ p.menulabel|default(p.title) }}
|
|
||||||
</a></li>
|
|
||||||
{% endfor %}
|
|
||||||
{% endif %}
|
|
||||||
{% if DISPLAY_CATEGORIES_ON_MENU %}
|
{% if DISPLAY_CATEGORIES_ON_MENU %}
|
||||||
{% for cat, null in categories %}
|
{% for cat, null in categories %}
|
||||||
<li {% if cat == category %}class="active"{% endif %}>
|
<li {% if cat == category %}class="active"{% endif %}>
|
||||||
|
|
Loading…
Reference in a new issue