<?phpclass A{ public $name; public $age; public function getASelf() { $this->name; var_dump($this); }}?>突然对this的原形好奇,如何打出它的原形呢
回复讨论(解决方案)
实例化Class A,调用getASelf()
或者
实例化后即
$a = new A();
var_dump($a);
原来对象是这玩意object(A)#1 (2) { ["name"]=> NULL ["age"]=> NULL }











