<?php $__currentLoopData = getConfig('lang'); $this->addLoop($__currentLoopData);$this->getFirstLoop();
 foreach($__currentLoopData as $langKey => $lang): $loop = $this->incrementLoopIndices();  ?>
 <?php 
 if($res->uri == 'home') {
 $langUri = ($lang['slug'] == '') ? '/' : '/' . $lang['slug'];
 }
 else {
 $langSlug = ($lang['slug'] == '') ? '' : '/' . $lang['slug'];
 $langUri = $langSlug . '/' . $res->uri;
 }
 ?>

 <a class="lang<?php echo \htmlentities(getLang() == $langKey ? ' active' : ''??'', ENT_QUOTES, 'UTF-8', false); ?> lang-link" 
 data-key="<?php echo \htmlentities($langKey??'', ENT_QUOTES, 'UTF-8', false); ?>"
 data-slug="<?php echo \htmlentities($langUri??'', ENT_QUOTES, 'UTF-8', false); ?>">
 <?php echo \htmlentities($lang['title']??'', ENT_QUOTES, 'UTF-8', false); ?>

 </a>
<?php endforeach; $this->popLoop(); $loop = $this->getFirstLoop(); ?>
