<? global $lang_id, $page;?>
<div id="languages">
  <div class="container">
    <div class="row">
      <div class="col-xs-12">
        <? if ( is_array( $this -> languages ) ):?>
          <ul>
            <? foreach ( $this -> languages as $lg ):?>
              <li <? if ( $lang_id == $lg['id'] ) echo 'class="active"';?>>
                <a href="<?= \front\factory\Pages::lang_url( $page['id'], $lg['id'], $lg['domain'], $this -> default_domain );?>" title="Język: <?= $lg['name'];?>">
                  <img src="/admin/css/lang-<?= $lg['id'];?>.jpg" alt="Język: <?= $lg['name'];?>">
                </a>
              </li>
            <? endforeach;?>
          </ul>
        <? endif;?>
      </div>
    </div>
  </div>
</div>