3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php var_dump(scandir('/etc'));
Output for 7.2.0
Warning: scandir(/etc): failed to open dir: Permission denied in /in/jrRvv on line 3 Warning: scandir(): (errno 13): Permission denied in /in/jrRvv on line 3 bool(false)
Output for 5.0.0 - 5.6.30, hhvm-3.10.1 - 3.17.3, 7.0.0 - 7.1.7
array(39) { [0]=> string(1) "." [1]=> string(2) ".." [2]=> string(12) "arch-release" [3]=> string(16) "bash.bash_logout" [4]=> string(11) "bash.bashrc" [5]=> string(8) "crypttab" [6]=> string(5) "fstab" [7]=> string(8) "gai.conf" [8]=> string(5) "group" [9]=> string(7) "gshadow" [10]=> string(4) "hhvm" [11]=> string(9) "host.conf" [12]=> string(5) "hosts" [13]=> string(7) "inputrc" [14]=> string(5) "issue" [15]=> string(11) "ld.so.cache" [16]=> string(10) "ld.so.conf" [17]=> string(12) "ld.so.conf.d" [18]=> string(10) "locale.gen" [19]=> string(9) "localtime" [20]=> string(10) "machine-id" [21]=> string(4) "motd" [22]=> string(4) "mtab" [23]=> string(9) "nscd.conf" [24]=> string(13) "nsswitch.conf" [25]=> string(8) "pacman.d" [26]=> string(6) "passwd" [27]=> string(7) "php.ini" [28]=> string(15) "php_archive.ini" [29]=> string(7) "profile" [30]=> string(9) "profile.d" [31]=> string(9) "protocols" [32]=> string(11) "resolv.conf" [33]=> string(3) "rpc" [34]=> string(9) "securetty" [35]=> string(8) "services" [36]=> string(6) "shadow" [37]=> string(6) "shells" [38]=> string(4) "skel" }
Output for 4.4.5 - 4.4.9
Fatal error: Call to undefined function: scandir() in /in/jrRvv on line 3
Process exited with code 255.
Output for 4.3.2 - 4.4.4
Fatal error: Call to undefined function: scandir() in /in/jrRvv on line 3
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Fatal error: Call to undefined function: scandir() in /in/jrRvv on line 3