#20549 [Bgs->]: register_global and scoping vars

From: Date: Fri, 22 Nov 2002 11:35:30 +0000
Subject: #20549 [Bgs->]: register_global and scoping vars
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-25553@lists.php.net to get a copy of this message
ID: 20549 Updated by: derick@php.net Reported By: somekool@mytradecenter.com -Status: Bogus +Status: Won\'t fix -Bug Type: *General Issues +Bug Type: Feature/Change Request Operating System: Slackware Linux PHP Version: 4.2.2 New Comment: That is not going to happen. Previous Comments: ------------------------------------------------------------------------ [2002-11-21 22:09:43] somekool@mytradecenter.com yes i enabled register_globals but i would like my variables to be really global and usable in every scope, even in user defined function function foo() { echo $varX; } without specifying "global $varX;" ------------------------------------------------------------------------ [2002-11-21 16:34:48] iliaa@php.net Not enough information was provided for us to be able to handle this bug. Please re-read the instructions at http://bugs.php.net/how-to-report.php If you can provide more information, feel free to add it to this bug and change the status back to "Open". Thank you for your interest in PHP. If you enable register_globals then variables passed via GET/POST/COOKIE will be avaliable in the global scope. ------------------------------------------------------------------------ [2002-11-21 13:27:35] somekool@mytradecenter.com Hi this is most a request than a regular bug report. we found that we can't access get and post vars in user defined function by using $var in PHP 4.2. even with register_globals set to on, variable cannot be accessed by using the common way. this require a lot of work to adapt our code and we prefer to take the responsability on our own. we understand the security issue, and appreciate that PHP take care of user security. but, can't we handle by our own the security problem ? is there any option to make External variables being global as it was ? thanks ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=20549&edit=1

« previous php.bugs (#25553) next »