Name of Class' instance

From: Date: Tue, 06 Feb 2001 22:04:13 +0000
Subject: Name of Class' instance
Groups: php.general 
Request: Send a blank email to php-general+get-38437@lists.php.net to get a copy of this message
I think I already know the answer to this question, but I just want to make certain. Is there a way that a class can know the name of the variable used to instantiate it? So if you do: $joeBob = new myClass(); "myClass" can somehow know that "joeBob" is the name of it's instance? I'm thinking 'no', but would like verification. Nothing I've been able to do has gotten this to work so that lends credence to my thinking, but again, I just want to be certain. Thanks! Chris

« previous php.general (#38437) next »