I have 2 sets of users that need access to a shared page. Each user has a different session assigned. Here is what I have. It allows access to 'client1' but not 'admin'
session_start();
if (!isset($_SESSION["client1"]) || $_SESSION["client1"] !== true) {
header("Location: ../../../login.php");
if (!isset($_SESSION["admin"]) || $_SESSION["admin"] !== true) {
header("Location: ../../../login.php");
exit;
}
}
Any help would be greatly appreciated. Thank you in advance.