|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #20533 problem unsetting variables by deref
Submitted: 2002-11-20 23:42 UTC Modified: 2002-11-21 00:42 UTC
From: sputnik at reflexx dot net Assigned:
Status: Not a bug Package: Variables related
PHP Version: 4.2.3 OS: FreeBSD 4.6
Private report: No CVE-ID: None
 [2002-11-20 23:42 UTC] sputnik at reflexx dot net
pKillVar is defined as a global elsewhere in the script.
Its value is "pendingScope".

global $pKillVar;
$delete_me = $pKillVar;
global $$delete_me;

does NOT work. however:

$delete_me = "somevar";
global $$delete_me;

does. Seems to be a problem unsetting variables in the global scope. Have been having numerous problems related to such.


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2002-11-21 00:42 UTC]
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at and the instructions on how to report
a bug at
PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Wed Nov 29 00:01:26 2023 UTC