<?php // Initialize the session session_start(); $guser= $_SESSION["guser"] ; // Check if the user is logged in, if not then redirect him to login page if(!isset($_SESSION["loggedin"]) || $_SESSION["loggedin"] !== true){ header("location: welcome.php"); exit; } else { if (intval($guser)>0) header("location: cosmos.php"); else header("location: ducky.php"); } ?>
Edit file:donky.php444