3v4l.org

run code in 300+ PHP versions simultaneously
<?php var_dump($x = fopen("data:text/plain,trololololo", 'r+')); var_dump(fwrite($x, '123'), rewind($x)); var_dump(stream_get_contents($x)); echo "\r\n"; var_dump($x = fopen("data:text/plain,trololololo", 'w')); var_dump(fwrite($x, '123'), rewind($x)); var_dump(stream_get_contents($x)); echo "\r\n"; var_dump($x = fopen("data:text/plain,trololololo", 'a')); var_dump(fwrite($x, '123'), rewind($x)); var_dump(stream_get_contents($x)); echo "\r\n";
Output for git.master, git.master_jit, rfc.property-hooks
resource(5) of type (stream) Notice: fwrite(): Stream is not writable in /in/4G4Qa on line 4 bool(false) bool(true) string(11) "trololololo" resource(7) of type (stream) Notice: fwrite(): Stream is not writable in /in/4G4Qa on line 8 bool(false) bool(true) string(11) "trololololo" resource(9) of type (stream) Notice: fwrite(): Stream is not writable in /in/4G4Qa on line 12 bool(false) bool(true) string(11) "trololololo"

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