when a user signs up on my website,they get a similar link;
website.com/confirm_register.php?id=2d3ca81caf061fe873b16b98573ebd10
after clicking the link ,they are directed to a similar link website.com/alerts.php
but the alerts.php checks for authentication,here is the code below;
as you can see the code above ,only checks for session,i also want to check if a user came direct from clicking the verfication link so that they can access automatically without having to login againPHP Code:require("inc/conn.php");
session_start();
if(!isset($_SESSION['username'])) {
header("Location: login.php");
}
cheers





Bookmarks