#24291 [NEW]: globals not working right
| From: | spagmoid at yahoo dot com | Date: | Sun, 22 Jun 2003 21:57:44 +0000 |
| Subject: | #24291 [NEW]: globals not working right | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-42350@lists.php.net to get a copy of this message | ||
From: spagmoid at yahoo dot com
Operating system: winXP
PHP version: 4.3.2
PHP Bug Type: Variables related
Bug description: globals not working right
Description:
------------
globals aren't working right - in repro, no value is echoed
Reproduce code:
---------------
Wang();
function Wang()
{
global $A, $B;
$A = 3;
$B = &$A; // should work, doesn't
// $GLOBALS["B"] = &$A; // works
Chung();
}
function Chung()
{
global $A, $B;
echo $B;
}
--
Edit bug report at http://bugs.php.net/?id=24291&edit=1
--
Try a CVS snapshot: http://bugs.php.net/fix.php?id=24291&r=trysnapshot
Fixed in CVS: http://bugs.php.net/fix.php?id=24291&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=24291&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=24291&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=24291&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=24291&r=support
Expected behavior: http://bugs.php.net/fix.php?id=24291&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=24291&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=24291&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=24291&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=24291&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=24291&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=24291&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=24291&r=gnused