better lang switcher
This commit is contained in:
parent
0909bb64ff
commit
f2a622bb3a
1 changed files with 4 additions and 4 deletions
|
@ -48,16 +48,16 @@
|
|||
<section>
|
||||
{% if page.lang == 'en' %}
|
||||
{% if page.fr_url == '' %}
|
||||
<p class="switcher"><a href="{{ page.url | remove_first: '/en' }}">FR</a>|EN</p>
|
||||
<p class="switcher"><a href="{{ page.url | remove_first: '/en' }}">🇫🇷</a></p>
|
||||
{% else %}
|
||||
<p class="switcher"><a href="{{ page.fr_url }}">FR</a>|EN</p>
|
||||
<p class="switcher"><a href="{{ page.fr_url }}">🇫🇷</a></p>
|
||||
{% endif %}
|
||||
{% include nav_en.html %}
|
||||
{% else %}
|
||||
{% if page.en_url == '' %}
|
||||
<p class="switcher">FR|<a href="/en{{page.url}}">EN</a></p>
|
||||
<p class="switcher"><a href="/en{{page.url}}">🇬🇧</a></p>
|
||||
{% else %}
|
||||
<p class="switcher">FR|<a href="{{ page.en_url }}">EN</a></p>
|
||||
<p class="switcher"><a href="{{ page.en_url }}">🇬🇧</a></p>
|
||||
{% endif %}
|
||||
{% include nav_fr.html %}
|
||||
{% endif %}
|
||||
|
|
Loading…
Reference in a new issue