- Output for 5.3.0 - 5.3.28, 5.4.0 - 5.4.28, 5.5.0 - 5.5.12
- Parse error: syntax error, unexpected '=' in /in/hPeET on line 11
Process exited with code 255.
<?php
class ParentClass {
public static $prop;
}
class ChildClass extends ParentClass {
}
ParentClass::prop = "first";
$parent = new ParentClass;
echo "parent 1: " . $parent::prop;
ChildClass::prop = "second";
$child = new ChildClass;
echo "child 1: " . $child::prop;
echo "parent 2: " . $parent::prop;