Menu
Hi,
I am trying to set a cooking using the PHP setcookie function’
header (“Set-Cookie: UserAuth=2; path=/”);
The way this function works is .. if the user is correctly authenticated, it sets a cookie and sends the user to the member page.
If i use
header (“Set-Cookie: UserAuth=2; path=/”);
followed by
header (“Location: abc.php”);
then the cookie is deleted. If i just leave it at the first header (for testing) then the cookie stays. Not sure what is happening here.
Any help appreciated.
Neel