Restore bad login message

This commit is contained in:
Steve Beaver 2017-08-30 08:21:40 -04:00
parent 19b24bccc6
commit 7d7c65c2ff
2 changed files with 13 additions and 2 deletions

View File

@ -1773,7 +1773,7 @@ function session_auth() {
exit;
} else {
/* give the user an error message */
$_SESSION['Login_Error'] = "Username or Password incorrect";
$_SESSION['Login_Error'] = gettext("Username or Password incorrect");
log_auth("webConfigurator authentication error for '{$_POST['usernamefld']}' from {$_SERVER['REMOTE_ADDR']}");
if (isAjax()) {
echo "showajaxmessage('{$_SESSION['Login_Error']}');";

View File

@ -359,7 +359,18 @@ if (is_ipaddr($http_host) && !$local_ip && !isset($config['system']['webgui']['n
</svg>
</div>
</div>
<div class="col-sm-8 nowarning msgbox text-center">
<!-- Header center message box -->
<div class="col-sm-4 nowarning msgbox text-center text-danger">
<?php
if (!empty($_POST['usernamefld'])) {
print("<h4>" . $_SESSION['Login_Error'] . "</h4>");
}
?>
</div>
<!-- Header right message box (hostname or msg) -->
<div class="col-sm-4 nowarning msgbox text-center">
<span id="hostspan">
<a><h4><?=$loginbannerstr?></h4></a>
</span>