Manual merge of pr/64 by @0x5f3

This commit is contained in:
jokob-sk
2022-08-05 10:57:16 +10:00
parent 7d50e3407b
commit e6d75b411a
10 changed files with 16 additions and 15 deletions

View File

@@ -3,7 +3,7 @@ session_start();
if ($_REQUEST['action'] == 'logout') {
session_destroy();
header('Location: /pialert/index.php');
header('Location: /index.php');
}
// ###################################
// ## Login settings locale start
@@ -40,7 +40,7 @@ $Pia_WebProtection = strtolower(trim($protection_line[1]));
if ($Pia_WebProtection == 'false')
{
header('Location: /pialert/devices.php');
header('Location: /devices.php');
$_SESSION["login"] = 1;
exit;
}
@@ -55,13 +55,13 @@ $Pia_Password = $password_line[1];
if ($Pia_Password == hash('sha256',$_POST["loginpassword"]))
{
header('Location: /pialert/devices.php');
header('Location: /devices.php');
$_SESSION["login"] = 1;
}
if ($_SESSION["login"] == 1)
{
header('Location: /pialert/devices.php');
header('Location: /devices.php');
}
if ($_SESSION["login"] != 1)
@@ -118,12 +118,12 @@ if ($ENABLED_DARKMODE === True) {
<body class="hold-transition login-page">
<div class="login-box">
<div class="login-logo">
<a href="/pialert/index2.php">Pi.<b>Alert</b></a>
<a href="/index2.php">Pi.<b>Alert</b></a>
</div>
<!-- /.login-logo -->
<div class="login-box-body">
<p class="login-box-msg"><?php echo $pia_lang['Login_Box'];?></p>
<form action="/pialert/index.php" method="post">
<form action="/index.php" method="post">
<div class="form-group has-feedback">
<input type="password" class="form-control" placeholder="<?php echo $pia_lang['Login_Psw-box'];?>" name="loginpassword">
<span class="glyphicon glyphicon-lock form-control-feedback"></span>