Hi all,
I have written this syntax..
$userid="anyname";
$lifetime=time() + 86400;
setcookie("zUID",$userid,$lifetime,"/");
It's working fine but sometimes after surfing some pages on my site. This cookie automatically got Dissappeared from the client ..I mean my PHP proogramme could'nt find it anymore.. I have written the following..
$HTTP_COOKIE_VARS["zUID"];
if (!isset($zUID))
{
echo("Sorry you are not logged in !!");
exit;
}
And user automatically logged off..
Where I am wrong..
Help me please..
Tabish