3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo implements Serializable { public function serialize() { } public function unserialize($serialized) { } } var_dump(unserialize(sprintf('O:%d:"%s":0:{}', strlen('Foo'), 'Foo')));
Output for git.master, git.master_jit
Deprecated: Foo implements the Serializable interface, which is deprecated. Implement __serialize() and __unserialize() instead (or in addition, if support for old PHP versions is necessary) in /in/OW4j1 on line 3 Warning: Erroneous data format for unserializing 'Foo' in /in/OW4j1 on line 9 Notice: unserialize(): Error at offset 13 of 14 bytes in /in/OW4j1 on line 9 bool(false)
Output for rfc.property-hooks
Deprecated: Foo implements the Serializable interface, which is deprecated. Implement __serialize() and __unserialize() instead (or in addition, if support for old PHP versions is necessary) in /in/OW4j1 on line 3 Warning: Erroneous data format for unserializing 'Foo' in /in/OW4j1 on line 9 Warning: unserialize(): Error at offset 13 of 14 bytes in /in/OW4j1 on line 9 bool(false)

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:
47 ms | 402 KiB | 8 Q