Help w/Cookie Problem

From: Date: Thu, 15 Mar 2001 17:42:28 +0000
Subject: Help w/Cookie Problem
Groups: php.general 
Request: Send a blank email to php-general+get-44078@lists.php.net to get a copy of this message
If I have a cookie request in a function, and check the value of a cookie, I get that there is no value, if I check for the value outside of the function, I see the value. What should I do to ? ( SAMPLE BELOW ) function f_check_security() { # $c_uas_time is the cookie I want the value of if(isset($c_uas_time)) { # I tried the above way to just check that it is there, then I tried the below to check the value # if($c_uas_time=="GREEN") { $access="GRANT"; setcookie("c_uas_time","GREEN",(time()+200),'/','domainname.com',0); } else { $access="DENY-GREEN"; } return($access); } I also tried this below to try and get the value .... echo "HTTP->" . $HTTP_COOKIE_VARS["c_uas_time"]; I appreciate your time....and look forward to stop banging my head against the wall.... 8^) ___________________________________________________________ Jack Sasportas

« previous php.general (#44078) next »