If you want to retrieve the class vars from within the class itself, use $this.<?phpclass Foo { var $a; var $b; var $c; var $d; var $e; function GetClassVars() { return array_keys(get_class_vars(get_class($this))); // $this }}$Foo = new Foo;$class_vars = $Foo->GetClassVars();foreach ($class_vars as $cvar){ echo $cvar . "<br />\n";}?>Produces, after PHP 4.2.0, the following:abcde