3v4l.org

run code in 300+ PHP versions simultaneously
<?php class testParent { public function f1() { echo 1; } public function f2() { echo 2; } } class testChild extends testParent{ public function f2($a) { //overriding function f2 echo $a; } } $test = new testChild(); echo $test->f2('a'); ?>

This is an error 404

There are `0` results


preferences:
144.05 ms | 1399 KiB | 7 Q