variable scope in nested functions
| From: | Filippo Veneri | Date: | Mon, 09 Dec 2002 12:58:28 +0000 |
| Subject: | variable scope in nested functions | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-127485@lists.php.net to get a copy of this message | ||
Is there a way to access a variable defined in a function from a nested
function, without putting the variable in the global scope?
Perhaps some code will make my question clearer:
function enclosing() {
$variable1;
function enclosed() {
can I access $variable1 from here?
}
}
Thanks,
fbv