3v4l.org

run code in 500+ PHP versions simultaneously
<?php class MyClass { private $hi = 'Hi'; protected $hello = 'Hello'; public $goodday = 'Goodday'; } $thing = new MyClass(); print json_encode($thing); // {"goodday":"Goodday"} print json_encode((array) $thing); // {"\u0000MyClass\u0000hi":"Hi","\u0000*\u0000hello":"Hello","goodday":"Goodday"}
Output for git.master_jit, git.master
{"goodday":"Goodday"}{"\u0000MyClass\u0000hi":"Hi","\u0000*\u0000hello":"Hello","goodday":"Goodday"}

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
22.35 ms | 853 KiB | 4 Q