3v4l.org

run code in 300+ PHP versions simultaneously
<?php $name = '/proc/self/mem'; $fp = fopen($name, 'r'); // send the right headers // dump the picture and stop the script echo fpassthru($fp); exit;
Output for 8.3.0 - 8.3.7
Warning: fopen(): open_basedir restriction in effect. File(/proc/self/mem) is not within the allowed path(s): (/tmp:/in:/etc) in /in/MgRpF on line 4 Warning: fopen(/proc/self/mem): Failed to open stream: Operation not permitted in /in/MgRpF on line 4 Fatal error: Uncaught TypeError: fpassthru(): Argument #1 ($stream) must be of type resource, false given in /in/MgRpF:9 Stack trace: #0 /in/MgRpF(9): fpassthru(false) #1 {main} thrown in /in/MgRpF on line 9
Process exited with code 255.
Output for 8.0.0 - 8.0.12, 8.0.14 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.18
Warning: fopen(): open_basedir restriction in effect. File(/proc/self/mem) is not within the allowed path(s): (/tmp:/in:/etc) in /in/MgRpF on line 4 Warning: fopen(/proc/self/mem): Failed to open stream: Operation not permitted in /in/MgRpF on line 4 Fatal error: Uncaught TypeError: fpassthru(): Argument #1 ($stream) must be of type resource, bool given in /in/MgRpF:9 Stack trace: #0 /in/MgRpF(9): fpassthru(false) #1 {main} thrown in /in/MgRpF on line 9
Process exited with code 255.
Output for 8.0.13
Notice: fpassthru(): Read of 8192 bytes failed with errno=5 Input/output error in /in/MgRpF on line 9 -1
Output for 7.4.33
Notice: fpassthru(): read of 8192 bytes failed with errno=5 Input/output error in /in/MgRpF on line 9 -1
Output for 7.3.0 - 7.3.31, 7.4.0 - 7.4.32
Warning: fopen(): open_basedir restriction in effect. File(/proc/self/mem) is not within the allowed path(s): (/tmp:/in:/etc) in /in/MgRpF on line 4 Warning: fopen(/proc/self/mem): failed to open stream: Operation not permitted in /in/MgRpF on line 4 Warning: fpassthru() expects parameter 1 to be resource, bool given in /in/MgRpF on line 9
Output for 7.1.10, 7.3.32 - 7.3.33
0
Output for 7.1.26 - 7.1.33, 7.2.17 - 7.2.33
Warning: fopen(): open_basedir restriction in effect. File(/proc/self/mem) is not within the allowed path(s): (/tmp:/in:/etc) in /in/MgRpF on line 4 Warning: fopen(/proc/self/mem): failed to open stream: Operation not permitted in /in/MgRpF on line 4 Warning: fpassthru() expects parameter 1 to be resource, boolean given in /in/MgRpF on line 9
Output for 7.1.20, 7.2.6
Warning: fopen(): open_basedir restriction in effect. File(/proc/self/mem) is not within the allowed path(s): (/tmp:/in) in /in/MgRpF on line 4 Warning: fopen(/proc/self/mem): failed to open stream: Operation not permitted in /in/MgRpF on line 4 Warning: fpassthru() expects parameter 1 to be resource, boolean given in /in/MgRpF on line 9
Output for 7.0.0 - 7.0.20, 7.1.0 - 7.1.7
Warning: fopen(): open_basedir restriction in effect. File(/proc/self/mem) is not within the allowed path(s): (/tmp/) in /in/MgRpF on line 4 Warning: fopen(/proc/self/mem): failed to open stream: Operation not permitted in /in/MgRpF on line 4 Warning: fpassthru() expects parameter 1 to be resource, boolean given in /in/MgRpF on line 9

preferences:
152.39 ms | 402 KiB | 203 Q