I'm trying to create a php cookie using
setcookie('usrid', $user_id, time()+3600);
When I checked this with the browser, the cookie is set with the correct value passed with the variable. But I couldn't retreive the value using $_COOKIE['usrid']
I tried to delete the cookie using setcookie("usrid", "", time()-3600);
,
but its not getting deleted.
Now when I try to get the value of cookie, it shows the value. Can anyone tell why is this happening?