Added ru language file (thanks), changes to tables and config option for pagination

This commit is contained in:
andryyy
2017-03-22 10:46:24 +01:00
parent aff7fa7671
commit 9623a7fa70
7 changed files with 482 additions and 12 deletions

View File

@@ -49,6 +49,7 @@
<li <?=($_SESSION['mailcow_locale'] == 'es') ? 'class="active"' : ''?>> <a href="?<?= http_build_query(array_merge($_GET, array("lang" => "es"))) ?>"><span class="lang-xs lang-lbl-full" lang="es"></span></a></li>
<li <?=($_SESSION['mailcow_locale'] == 'nl') ? 'class="active"' : ''?>> <a href="?<?= http_build_query(array_merge($_GET, array("lang" => "nl"))) ?>"><span class="lang-xs lang-lbl-full" lang="nl"></span></a></li>
<li <?=($_SESSION['mailcow_locale'] == 'pt') ? 'class="active"' : ''?>> <a href="?<?= http_build_query(array_merge($_GET, array("lang" => "pt"))) ?>"><span class="lang-xs lang-lbl-full" lang="pt"></span></a></li>
<li <?=($_SESSION['mailcow_locale'] == 'ru') ? 'class="active"' : ''?>> <a href="?<?= http_build_query(array_merge($_GET, array("lang" => "ru"))) ?>"><span class="lang-xs lang-lbl-full" lang="ru"></span></a></li>
</ul>
</li>
<?php

View File

@@ -69,6 +69,10 @@ if (isset($_COOKIE['language'])) {
$_SESSION['mailcow_locale'] = 'pt';
setcookie('language', 'pt');
break;
case "ru":
$_SESSION['mailcow_locale'] = 'ru';
setcookie('language', 'ru');
break;
}
}
if (isset($_GET['lang'])) {
@@ -93,6 +97,10 @@ if (isset($_GET['lang'])) {
$_SESSION['mailcow_locale'] = 'pt';
setcookie('language', 'pt');
break;
case "ru":
$_SESSION['mailcow_locale'] = 'ru';
setcookie('language', 'ru');
break;
}
}
require_once 'lang/lang.en.php';

View File

@@ -26,7 +26,7 @@ $FORM_ACTION = "previous";
$MC_DKIM_TXTS = "/data/dkim/txt";
$MC_DKIM_KEYS = "/data/dkim/keys";
// Change default language, "en", "pt", "de" or "nl"
// Change default language, "en", "es" "pt", "de", "ru" or "nl"
$DEFAULT_LANG = "en";
// Change theme (default: lumen)
@@ -50,5 +50,8 @@ $MAILCOW_APPS = array(
// ),
);
// Rows until pagination begins
$PAGINATION_SIZE = 10;
?>