PHP 4.0 Bug #5363: problem with class and HTTP_COOKIE_VARS
| From: | jorge at ctyd dot com dot mx | Date: | Tue, 04 Jul 2000 18:26:20 +0000 |
| Subject: | PHP 4.0 Bug #5363: problem with class and HTTP_COOKIE_VARS | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-23348@lists.php.net to get a copy of this message | ||
From: jorge@ctyd.com.mx
Operating system: Linux Red Hat 6.2
PHP version: 4.0.0
PHP Bug Type: Other
Bug description: problem with class and HTTP_COOKIE_VARS
If i try to get the vaule of a cookie inside the class, the command
HTTP_COOKIE_VARS return "" but if the same command run outside the class
return the correct value
Example
Archivo userctl.inc
<?
class userctl {
function userctl() {
print $HTTP_COOKIE_VARS["ctl_user_cookie"]; // return ""
}
?>
Archivo test.phpA
<?
include("./userctl.inc");
$user = new userctl;
print $HTTP_COOKIE_VARS["ctl_user_cookie"]; //return "value"
?>