<?php class A{ public function __get($name){ return "A"; } public function __set($name,$value){ $this->{$name} = $value; } } $a = new A(); $k = $a->b = "B"; var_dump($a,$k);
You have javascript disabled. You will not be able to edit any code.