I have two pages admin page and a super admin page.. i just want to have rights of admin page too.. when i login as a super admin
currently to login admin page i use
if(!isset($_SESSION['admin'])) //if admin not in session
{
header("Location: home.php");
}
and this works fine but when i use this condition
if((!isset($_SESSION['admin'])) || (!isset($_SESSION['super_admin']))) //either admin or super admin is not in session
{
header ("Location: home.php");
}
which means either admin or super admin can have access to this page ... (this condition is what i think should be) I login as admin and i get the following error:
The page isn't redirecting properly.
Is there any way to access admin's page when I'm in super admin session?