RE: [PHP] $DOCUMENT_ROOT -- didn't work from a class..
| From: | php3 at developersdesk dot com | Date: | Wed, 30 Aug 2000 11:21:57 +0000 |
| Subject: | RE: [PHP] $DOCUMENT_ROOT -- didn't work from a class.. | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-14364@lists.php.net to get a copy of this message | ||
Addressed to: Brian Clark <brianj@ais.ais-gwd.com>
php-general@lists.php.net
** Reply to note from Brian Clark <brianj@ais.ais-gwd.com> Wed, 30 Aug 2000 05:10:01 -0400
>Helps if you "global $docRoot" inside the function...
>
> Well, no, I've never had to use global inside a class. Objects are
> supposed to have an isolated namespace.
Actually it is functions that have isolated namespaces. See:
http://www.php.net/manual/language.variables.scope.php
Objects have other limitiations on namespace, but the function is what
got you.
Rick Widmer
Internet Marketing Specialists
www.developersdesk.com