Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:11923 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 9181 invoked by uid 1010); 4 Aug 2004 23:37:23 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 9150 invoked by uid 1007); 4 Aug 2004 23:37:23 -0000 Message-ID: <20040804233723.9149.qmail@pb1.pair.com> To: internals@lists.php.net Date: Thu, 05 Aug 2004 01:35:32 +0200 User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7) Gecko/20040514 X-Accept-Language: en-us, en MIME-Version: 1.0 X-Enigmail-Version: 0.84.2.0 X-Enigmail-Supports: pgp-inline, pgp-mime Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Posted-By: 212.106.249.226 Subject: Variable Variables and Superglobals From: el3tro2@tiscali.es ("A.Rico") Using Variable Variables works fine inside functions for global defined variables if you declare them as global inside the function. Suprinsingly, it does not seem to work with superglobals. Take the following example: // code //////////////////////////////////////////////////////////// // Output ///////////////////////////////////////////////////////// Windows_NT Var 1 glob_var _ENV Var 1 Windows_NT --- In foo1 -------------- glob_var -------------------------- --- In foo2 -------------- glob_var Var 1 -------------------------- --- In foo3 -------------- glob_var -------------------------- --- In foo4 -------------- glob_var Var 1 -------------------------- --- In foo5 -------------- _ENV -------------------------- --- In foo6 -------------- _ENV -------------------------- --- In foo7 -------------- _ENV -------------------------- --- In foo8 -------------- _ENV -------------------------- --- In foo9 -------------- Windows_NT -------------------------- // Version ////////////////////////////////////////////// PHP 4.3.7 (cgi-fcgi) (built: Jun 2 2004 15:49:31) Copyright (c) 1997-2004 The PHP Group Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies // End ////////////////////////////////////////////////// I'm doing something wrong? Or this is the expected behavior? Thank you in advance