get_class()

From: Date: Tue, 17 Apr 2001 16:25:33 +0000
Subject: get_class()
Groups: php.general 
Request: Send a blank email to php-general+get-49001@lists.php.net to get a copy of this message
Given the following code: ----- class myClass { function myClass() { $classVar = get_class( $this ); } } $thisInstance = new myClass(); ----- What value should $classVar contain? "myClass" or "thisInstance" ? The documentation leads me to believe that it is the latter value, but in practice it contains the former. If it is supposed to have the latter value, is there any way I can get the fomer? Any way that I can get the name "thisInstance"? Chris

« previous php.general (#49001) next »