<?php class foo { public static function getInstance() { return new self(); } } class bar extends foo { } $obj = bar::getInstance(); var_dump($obj);
You have javascript disabled. You will not be able to edit any code.