Skip to content

Commit

Permalink
Update check_login.php If standard
Browse files Browse the repository at this point in the history
  • Loading branch information
ssteeltm committed May 4, 2024
1 parent bab66bf commit 17eb51b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions check_login.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,11 @@

// Check user is logged in with a valid session
if (!isset($_SESSION['logged']) || !$_SESSION['logged']) {
if($_SERVER["REQUEST_URI"] == "/")
if ($_SERVER["REQUEST_URI"] == "/") {
header("Location: login.php");
else
} else {
header("Location: login.php?last_visited=" . base64_encode($_SERVER["REQUEST_URI"]) );
}
exit;
}

Expand Down

0 comments on commit 17eb51b

Please sign in to comment.