Bug #16981 Updated: Variable Scrope suggestion

From: Date: Thu, 02 May 2002 22:58:41 +0000
Subject: Bug #16981 Updated: Variable Scrope suggestion
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-6791@lists.php.net to get a copy of this message
ID: 16981 Updated by: Lakario@msn.com Reported By: Lakario@msn.com -Status: Open +Status: Closed Bug Type: Variables related Operating System: Windows XP PHP Version: 4.1.2 New Comment: Sorry bout that, I figured out what I wasn't doing... Previous Comments: ------------------------------------------------------------------------ [2002-05-02 18:51:39] Lakario@msn.com Okay basically this isn't a bug, more of an annoyance though I thought it should be pointed out. As you all know variable scope in functions determines that $var1 outside a function is not the same a $var1 inside the function, so you must pass $var1 to the function. Basic stuff. Anyhow, there are many variables built into PHP such as $PHP_SELF that still comply to the variable scope rules, which I think is *very* annoying. I do not think it should be necessary to pass something like $PHP_SELF to your function if you need to call it within. I dunno, maybe I'm just whining, but there you have it. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=16981&edit=1

« previous php.bugs (#6791) next »