mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2024-10-22 10:46:04 +03:00
Revert "Avoid leaking user locale preference to the web"
This reverts commit 66c34ddb6e
.
This commit is contained in:
parent
a126a7b493
commit
ec6eac2ba1
2 changed files with 8 additions and 8 deletions
|
@ -7,7 +7,7 @@
|
||||||
<meta name="description" content="qBittorrent WebUI">
|
<meta name="description" content="qBittorrent WebUI">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
|
||||||
<title>qBittorrent WebUI</title>
|
<title>qBittorrent QBT_TR(WebUI)QBT_TR[CONTEXT=OptionsDialog]</title>
|
||||||
|
|
||||||
<link rel="icon" type="image/png" href="images/qbittorrent32.png" />
|
<link rel="icon" type="image/png" href="images/qbittorrent32.png" />
|
||||||
<link rel="icon" type="image/svg+xml" href="images/qbittorrent-tray.svg" />
|
<link rel="icon" type="image/svg+xml" href="images/qbittorrent-tray.svg" />
|
||||||
|
@ -22,25 +22,25 @@
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
<noscript id="noscript">
|
<noscript id="noscript">
|
||||||
<h1>JavaScript Required! You must enable JavaScript for the WebUI to work properly</h1>
|
<h1>QBT_TR(JavaScript Required! You must enable JavaScript for the WebUI to work properly)QBT_TR[CONTEXT=HttpServer]</h1>
|
||||||
</noscript>
|
</noscript>
|
||||||
<div id="main">
|
<div id="main">
|
||||||
<h1>qBittorrent WebUI</h1>
|
<h1>qBittorrent QBT_TR(WebUI)QBT_TR[CONTEXT=OptionsDialog]</h1>
|
||||||
<div id="logo" class="col">
|
<div id="logo" class="col">
|
||||||
<img src="images/qbittorrent-tray.svg" alt="qBittorrent logo" />
|
<img src="images/qbittorrent-tray.svg" alt="qBittorrent logo" />
|
||||||
</div>
|
</div>
|
||||||
<div id="formplace" class="col">
|
<div id="formplace" class="col">
|
||||||
<form id="loginform">
|
<form id="loginform">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<label for="username" class="qbt-translatable" data-i18n="Username">Username</label><br />
|
<label for="username">QBT_TR(Username)QBT_TR[CONTEXT=HttpServer]</label><br />
|
||||||
<input type="text" id="username" name="username" autocomplete="username" autofocus required />
|
<input type="text" id="username" name="username" autocomplete="username" autofocus required />
|
||||||
</div>
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<label for="password" class="qbt-translatable" data-i18n="Password">Password</label><br />
|
<label for="password">QBT_TR(Password)QBT_TR[CONTEXT=HttpServer]</label><br />
|
||||||
<input type="password" id="password" name="password" autocomplete="current-password" required />
|
<input type="password" id="password" name="password" autocomplete="current-password" required />
|
||||||
</div>
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<input type="submit" id="loginButton" class="qbt-translatable" data-i18n="Login" value="Login" />
|
<input type="submit" id="loginButton" value="QBT_TR(Login)QBT_TR[CONTEXT=HttpServer]" />
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -111,13 +111,13 @@ function submitLoginForm(event) {
|
||||||
if ((xhr.status === 200) && (xhr.responseText === "Ok."))
|
if ((xhr.status === 200) && (xhr.responseText === "Ok."))
|
||||||
location.replace(location);
|
location.replace(location);
|
||||||
else
|
else
|
||||||
errorMsgElement.textContent = i18next.t('Invalid Username or Password.');
|
errorMsgElement.textContent = 'QBT_TR(Invalid Username or Password.)QBT_TR[CONTEXT=HttpServer]';
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
xhr.addEventListener('error', () => {
|
xhr.addEventListener('error', () => {
|
||||||
errorMsgElement.textContent = (xhr.responseText !== "")
|
errorMsgElement.textContent = (xhr.responseText !== "")
|
||||||
? xhr.responseText
|
? xhr.responseText
|
||||||
: i18next.t('Unable to log in, server is probably unreachable.');
|
: 'QBT_TR(Unable to log in, qBittorrent is probably unreachable.)QBT_TR[CONTEXT=HttpServer]';
|
||||||
});
|
});
|
||||||
|
|
||||||
const usernameElement = document.getElementById('username');
|
const usernameElement = document.getElementById('username');
|
||||||
|
|
Loading…
Reference in a new issue