php-general | 2001062
Date: 06/24/01
- Next message: John Meyer: "Re: [PHP] Percentages"
- Previous message: David Robley: "Re: [PHP] $PHP_SELF name space?"
- In reply to: Kent Sandvik: "[PHP] $PHP_SELF name space?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
$PHP_SELF is a global variable. You're trying to call it from inside a
function, which won't work unless you declare it as global to the function
(unless you have some thing in the php.ini file set that I don't remember
off the top of my head what it's called which will make all that stuff
global anyway). You've got to do:
class xCrumbs
{
function Render(){
global $PHP_SELF;
echo $PHP_SELF;
}
}
$crumbs = new xCrumbs();
$crumbs->Render();
--Jason
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe <email protected> For additional commands, e-mail: php-general-help <email protected> To contact the list administrators, e-mail: php-list-admin <email protected>
- Next message: John Meyer: "Re: [PHP] Percentages"
- Previous message: David Robley: "Re: [PHP] $PHP_SELF name space?"
- In reply to: Kent Sandvik: "[PHP] $PHP_SELF name space?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

