mirror of
https://github.com/unraid/webgui.git
synced 2026-05-11 23:01:41 -05:00
Merge pull request #680 from bergware/mutli-language
Multi-language support
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
Menu="Buttons"
|
||||
Menu="Buttons:4"
|
||||
Title="Feedback"
|
||||
Icon="icon-u-chat"
|
||||
Tag="icon-u-chat"
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
Menu="Buttons"
|
||||
Menu="Buttons:7"
|
||||
Title="Help"
|
||||
Icon="icon-u-help"
|
||||
Code="e934"
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
Menu="Buttons"
|
||||
Menu="Buttons:5"
|
||||
Title="Info"
|
||||
Icon="icon-u-display"
|
||||
Code="e930"
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
Menu="Buttons"
|
||||
Menu="Buttons:1"
|
||||
Title="English"
|
||||
Icon="icon-u-switch"
|
||||
Code="e982"
|
||||
@@ -16,10 +16,17 @@ Code="e982"
|
||||
*/
|
||||
?>
|
||||
<script>
|
||||
<?if (count(glob('/var/log/plugins/lang-*.xml'))==0):?>
|
||||
// hide switch button when no other language packs
|
||||
$(function(){$('#nav-item.LanguageButton').hide();});
|
||||
<?endif;?>
|
||||
|
||||
function LanguageButton() {
|
||||
switchLanguage('');
|
||||
var locale = '<?=$locale?>';
|
||||
if (locale) switchLanguage('');
|
||||
}
|
||||
|
||||
function switchLanguage(lang) {
|
||||
$.post('/webGui/include/LanguageReset.php',{lang:lang},function(){refresh();});
|
||||
$.post('/webGui/include/LanguageReset.php',{lang:lang},function(){location.reload();});
|
||||
}
|
||||
</script>
|
||||
@@ -1,4 +1,4 @@
|
||||
Menu="Buttons"
|
||||
Menu="Buttons:6"
|
||||
Title="Log"
|
||||
Icon="icon-u-log"
|
||||
Code="e936"
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
Cond="file_exists('/etc/nginx/htpasswd')"
|
||||
Menu="Buttons:1"
|
||||
Menu="Buttons:2"
|
||||
Title="Logout"
|
||||
Icon="icon-u-logout"
|
||||
Code="e937"
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
Menu="Buttons:2"
|
||||
Menu="Buttons:3"
|
||||
Title="Terminal"
|
||||
Icon="icon-u-terminal"
|
||||
Href="/webterminal/"
|
||||
|
||||
Reference in New Issue
Block a user