3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php interface Interfaze { public function hello($name); } class Clazz implements Interfaze { public function __construct() { $this->hello(); } public function hello($name) { echo "Hello, $name!"; } } class ClazzChild extends Clazz { public function __construct() { echo "Loaded from the child class."; parent::__construct(); } } $childclass = new ChildClazz; $childclass;
based on u8ErT
Output for 7.0.0 - 7.3.0rc4
Fatal error: Uncaught Error: Class 'ChildClazz' not found in /in/C8Anj:27 Stack trace: #0 {main} thrown in /in/C8Anj on line 27
Process exited with code 255.
Output for 5.3.19 - 5.6.28
Fatal error: Class 'ChildClazz' not found in /in/C8Anj on line 27
Process exited with code 255.