diff options
author | Jonas Kohl | 2024-09-17 13:39:12 +0200 |
---|---|---|
committer | Jonas Kohl | 2024-09-17 13:39:12 +0200 |
commit | f6dd78734f86f8daed7c5d472e7a199301095ff8 (patch) | |
tree | ef173ed502e189b25c6b5af08db982943adca718 /src/application/views/template_end.php | |
parent | e8ab5cbddd018f311e2d942c048203b8b3221e4e (diff) |
More theme and i18n stuff
Diffstat (limited to 'src/application/views/template_end.php')
-rw-r--r-- | src/application/views/template_end.php | 41 |
1 files changed, 39 insertions, 2 deletions
diff --git a/src/application/views/template_end.php b/src/application/views/template_end.php index d12e2ff..f322b36 100644 --- a/src/application/views/template_end.php +++ b/src/application/views/template_end.php @@ -3,8 +3,41 @@ <div class="container"> <div class="panel panel-default"> <div class="panel-body"> - © <?= date("Y") ?> <?= htmlentities(env("MYSTIC_FORUM_COPYRIGHT") ?? env("MYSTIC_FORUM_TITLE") ?? "Forum") ?>. - Powered by <a href="https://git.jkohl.link/mystic-forum.git/">Mystic Forum</a> + <table style="border-collapse: collapse; width: 100%; background: none"> + <tbody> + <tr> + <td style="padding: 0; vertical-align: middle; text-align: left; width: 100%" class="text-normal"> + © <?= date("Y") ?> <?= htmlentities(env("MYSTIC_FORUM_COPYRIGHT") ?? env("MYSTIC_FORUM_TITLE") ?? "Forum") ?>. + Powered by <a href="https://git.jkohl.link/mystic-forum.git/">mysticBB</a>. + </td> + <td style="padding: 0; vertical-align: middle; text-align: right; white-space: nowrap" class="text-normal"> + <form action="?_action=settheme" class="form-inline seamless-inline" method="post"> + <input type="hidden" name="next" value="<?= htmlentities($_SERVER["REQUEST_URI"]) ?>"> + <div class="form-group"> + <label for="theme-select"><?= __("Theme:") ?></label> + <select class="form-control input-sm auto-submit" id="theme-select" name="theme"> + <?php foreach ($availableThemes as $themeKey => $themeInfo): ?> + <option value="<?= htmlentities($themeKey) ?>" <?= $themeKey === $currentTheme ? " selected" : "" ?>><?= htmlentities($themeInfo->name) ?></option> + <?php endforeach; ?> + </select> + </div> + </form> + + <form action="?_action=setlang" class="form-inline seamless-inline" method="post"> + <input type="hidden" name="next" value="<?= htmlentities($_SERVER["REQUEST_URI"]) ?>"> + <div class="form-group"> + <label for="lang-select"><?= __("Language:") ?></label> + <select class="form-control input-sm auto-submit" id="lang-select" name="lang"> + <?php foreach ($availableLangs as $langKey => $langName): ?> + <option value="<?= htmlentities($langKey) ?>" <?= $langKey === $currentLang ? " selected" : "" ?>><?= htmlentities($langName) ?></option> + <?php endforeach; ?> + </select> + </div> + </form> + </td> + </tr> + </tbody> + </table> </div> </div> </div> @@ -24,6 +57,10 @@ $(function() { ], ]) ?> + $(".auto-submit").on("change", function() { + $(this)[0].form.submit(); + }); + $("._time").each(function(i, e) { var date = new Date($(e).text()); $(e).text(date.toLocaleString()); |