3v4l.org

run code in 300+ PHP versions simultaneously
<?php $d="./var/log/pacman.log"; echo substr(decoct( fileperms($d)),1); echo readfile($d)?>
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, 8.3.0 - 8.3.7
Warning: fileperms(): open_basedir restriction in effect. File(./var/log/pacman.log) is not within the allowed path(s): (/tmp:/in:/etc) in /in/S4gDb on line 1 Warning: readfile(): open_basedir restriction in effect. File(./var/log/pacman.log) is not within the allowed path(s): (/tmp:/in:/etc) in /in/S4gDb on line 1 Warning: readfile(./var/log/pacman.log): Failed to open stream: Operation not permitted in /in/S4gDb on line 1
Output for 7.3.32 - 7.3.33, 7.4.33, 8.0.13
00644[2021-10-24T13:19:16+0200] [PACMAN] Running 'pacman -r /var/lib/machines/phpShell.new/ -Sy --cachedir=/var/lib/machines/phpShell.new//var/cache/pacman/pkg --noconfirm filesystem' [2021-10-24T13:19:16+0200] [PACMAN] synchronizing package lists [2021-10-24T13:19:16+0200] [ALPM] transaction started [2021-10-24T13:19:16+0200] [ALPM] installed iana-etc (20210903-1) [2021-10-24T13:19:16+0200] [ALPM] installed filesystem (2021.05.31-1) [2021-10-24T13:19:16+0200] [ALPM] transaction completed 489
Output for 7.1.25 - 7.1.33, 7.2.0 - 7.2.33, 7.3.0 - 7.3.31, 7.4.0 - 7.4.32
Warning: fileperms(): open_basedir restriction in effect. File(./var/log/pacman.log) is not within the allowed path(s): (/tmp:/in:/etc) in /in/S4gDb on line 1 Warning: readfile(): open_basedir restriction in effect. File(./var/log/pacman.log) is not within the allowed path(s): (/tmp:/in:/etc) in /in/S4gDb on line 1 Warning: readfile(./var/log/pacman.log): failed to open stream: Operation not permitted in /in/S4gDb on line 1
Output for 7.0.20, 7.1.5 - 7.1.10
Warning: fileperms(): stat failed for ./var/log/pacman.log in /in/S4gDb on line 1 Warning: readfile(./var/log/pacman.log): failed to open stream: Permission denied in /in/S4gDb on line 1

preferences:
162.34 ms | 402 KiB | 194 Q