3v4l.org

run code in 300+ PHP versions simultaneously
<?php $stream = fopen('data://text/plain,', 'w+'); fputcsv($stream, array('test','csv "derp"')); rewind($stream); $csv = stream_get_contents($stream); fclose($stream); echo $csv;
Output for 8.0.0 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.18, 8.3.0 - 8.3.6
Notice: fputcsv(): Stream is not writable in /in/oEmPI on line 4
Output for 5.2.0 - 5.2.17, 5.3.0 - 5.3.29, 5.4.0 - 5.4.45, 5.5.0 - 5.5.37, 5.6.0 - 5.6.28, 7.0.0 - 7.0.20, 7.1.0 - 7.1.25, 7.2.0 - 7.2.33, 7.3.0 - 7.3.33, 7.4.0 - 7.4.33
test,"csv ""derp"""
Output for 5.1.0 - 5.1.6
Notice: fopen(): Unable to find the wrapper "data" - did you forget to enable it when you configured PHP? in /in/oEmPI on line 3 Warning: fopen(data://text/plain,): failed to open stream: No such file or directory in /in/oEmPI on line 3 Warning: fputcsv() expects parameter 1 to be resource, boolean given in /in/oEmPI on line 4 Warning: rewind(): supplied argument is not a valid stream resource in /in/oEmPI on line 5 Warning: stream_get_contents() expects parameter 1 to be resource, boolean given in /in/oEmPI on line 6 Warning: fclose(): supplied argument is not a valid stream resource in /in/oEmPI on line 7
Output for 5.0.0 - 5.0.5
Notice: fopen(): Unable to find the wrapper "data" - did you forget to enable it when you configured PHP? in /in/oEmPI on line 3 Warning: fopen(data://text/plain,): failed to open stream: No such file or directory in /in/oEmPI on line 3 Fatal error: Call to undefined function fputcsv() in /in/oEmPI on line 4
Process exited with code 255.
Output for 4.4.5 - 4.4.9
Notice: fopen(): Unable to find the wrapper "data" - did you forget to enable it when you configured PHP? in /in/oEmPI on line 3 Warning: fopen(data://text/plain,): failed to open stream: No such file or directory in /in/oEmPI on line 3 Fatal error: Call to undefined function: fputcsv() in /in/oEmPI on line 4
Process exited with code 255.
Output for 4.3.2 - 4.3.11, 4.4.0 - 4.4.4
Notice: fopen(): Unable to find the wrapper "data" - did you forget to enable it when you configured PHP? in /in/oEmPI on line 3 Warning: fopen(data://text/plain,): failed to open stream: No such file or directory in /in/oEmPI on line 3 Fatal error: Call to undefined function: fputcsv() in /in/oEmPI on line 4
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Notice: fopen() [http://www.php.net/function.fopen]: Unable to find the wrapper "data" - did you forget to enable it when you configured PHP? in /in/oEmPI on line 3 Warning: fopen(data://text/plain,) [http://www.php.net/function.fopen]: failed to create stream: No such file or directory in /in/oEmPI on line 3 Fatal error: Call to undefined function: fputcsv() in /in/oEmPI on line 4

preferences:
238.73 ms | 402 KiB | 366 Q