templates/front/theme1/partials/header/elements/_lang.html.twig line 1

Open in your IDE?
  1. {% if languages and languages|length > 1 %}
  2.     <div class="lang">
  3.         <ul class="d-flex">
  4.             {% for lang in languages %}
  5.                 <li class="{{lang.languagecode}} {{ locale == lang.languagecode ? 'active' : '' }}">
  6.                     {% if locale == lang.languagecode %}
  7.                         {% if lang.flag %}<img src="/uploads/flags/{{lang.flag}}" alt="{{lang.languagecode}}" width="25"/>{% endif %}
  8.                     {% else %}
  9.                         <a title="{{lang.name}}" href="{{ path('setlocale_langauge', {'language': lang.languagecode }) }}">
  10.                             {% if lang.flag %}<img src="/uploads/flags/{{lang.flag}}" alt="{{lang.languagecode}}" width="25"/>{% endif %}
  11.                         </a>
  12.                     {% endif %}
  13.                     
  14.                 </li>
  15.             {% endfor %}
  16.         </ul>
  17.     </div>
  18. {% endif %}