3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php print_r(scandir("/etc")); echo file_get_contents("/etc/php.ini");
Output for 5.6.28, 7.0.14 - 7.1.0
Array ( [0] => . [1] => .. [2] => ImageMagick-6 [3] => ODBCDataSources [4] => arch-release [5] => bash.bash_logout [6] => bash.bashrc [7] => ca-certificates [8] => crypttab [9] => default [10] => environment [11] => fonts [12] => fstab [13] => gai.conf [14] => group [15] => gshadow [16] => hhvm [17] => host.conf [18] => hosts [19] => inputrc [20] => issue [21] => krb5.conf [22] => ld.so.cache [23] => ld.so.conf [24] => ld.so.conf.d [25] => locale.gen [26] => localtime [27] => login.defs [28] => machine-id [29] => mke2fs.conf [30] => motd [31] => mtab [32] => netconfig [33] => nscd.conf [34] => nsswitch.conf [35] => odbc.ini [36] => odbcinst.ini [37] => openldap [38] => pacman.d [39] => pam.d [40] => passwd [41] => php.ini [42] => php_archive.ini [43] => pkcs11 [44] => profile [45] => profile.d [46] => protocols [47] => request-key.conf [48] => request-key.d [49] => resolv.conf [50] => rpc [51] => securetty [52] => security [53] => services [54] => shadow [55] => shells [56] => skel [57] => ssl ) [PHP] ; ini_set should be in here too if you're concerned about security disable_functions = pcntl_fork,phpinfo,mail max_execution_time = 3 memory_limit = 64M enable_dl = Off ; for consistency of older versions allow_call_time_pass_reference = Off html_errors = Off extension=gmp.so extension=iconv.so extension=intl.so extension=bcmath.so zend_extension=opcache.so ; show all errors by default, if we'd lower this in the script we'll miss some parser notices error_reporting = -1 display_errors = On display_startup_errors = On log_errors = Off report_memleaks = On [Date] date.timezone = Europe/Amsterdam
Output for 5.5.24 - 5.5.28, 5.5.35 - 5.6.12, 5.6.21, 7.0.6
Array ( [0] => . [1] => .. [2] => ImageMagick-6 [3] => ODBCDataSources [4] => arch-release [5] => bash.bash_logout [6] => bash.bashrc [7] => ca-certificates [8] => crypttab [9] => default [10] => environment [11] => fonts [12] => fstab [13] => gai.conf [14] => group [15] => gshadow [16] => hhvm [17] => host.conf [18] => hosts [19] => inputrc [20] => issue [21] => krb5.conf [22] => ld.so.cache [23] => ld.so.conf [24] => ld.so.conf.d [25] => locale.gen [26] => localtime [27] => login.defs [28] => mke2fs.conf [29] => motd [30] => mtab [31] => netconfig [32] => nscd.conf [33] => nsswitch.conf [34] => odbc.ini [35] => odbcinst.ini [36] => openldap [37] => pacman.d [38] => pam.d [39] => passwd [40] => php.ini [41] => php_archive.ini [42] => pkcs11 [43] => profile [44] => profile.d [45] => protocols [46] => request-key.conf [47] => request-key.d [48] => resolv.conf [49] => rpc [50] => securetty [51] => security [52] => services [53] => shadow [54] => shells [55] => skel [56] => ssl ) [PHP] ; Precision of floats in serialized output serialize_precision = 24 ; ini_set should be in here too if you're concerned about security disable_functions = pcntl_fork,phpinfo,mail max_execution_time = 3 memory_limit = 64M enable_dl = Off ; for consistency of older versions allow_call_time_pass_reference = Off html_errors = Off extension=intl.so extension=bcmath.so zend_extension=opcache.so ; show all errors by default, if we'd lower this in the script we'll miss some parser notices error_reporting = -1 display_errors = On display_startup_errors = On log_errors = Off report_memleaks = On [Date] date.timezone = Europe/Amsterdam
Output for 5.5.29 - 5.5.32, 5.5.34, 5.6.13 - 5.6.17, 5.6.20, hhvm-3.10.0, 7.0.0 - 7.0.3, 7.0.5
Array ( [0] => . [1] => .. [2] => ImageMagick-6 [3] => ODBCDataSources [4] => arch-release [5] => bash.bash_logout [6] => bash.bashrc [7] => ca-certificates [8] => crypttab [9] => default [10] => environment [11] => fonts [12] => fstab [13] => gai.conf [14] => group [15] => gshadow [16] => hhvm [17] => host.conf [18] => hosts [19] => inputrc [20] => issue [21] => krb5.conf [22] => ld.so.cache [23] => ld.so.conf [24] => ld.so.conf.d [25] => locale.gen [26] => localtime [27] => login.defs [28] => mke2fs.conf [29] => motd [30] => mtab [31] => netconfig [32] => nscd.conf [33] => nsswitch.conf [34] => odbc.ini [35] => odbcinst.ini [36] => openldap [37] => pacman.d [38] => pam.d [39] => passwd [40] => php.ini [41] => pkcs11 [42] => profile [43] => profile.d [44] => protocols [45] => request-key.conf [46] => request-key.d [47] => resolv.conf [48] => rpc [49] => securetty [50] => security [51] => services [52] => shadow [53] => shells [54] => skel [55] => ssl ) [PHP] ; Precision of floats in serialized output serialize_precision = 24 ; ini_set should be in here too if you're concerned about security disable_functions = pcntl_fork,phpinfo,mail max_execution_time = 3 memory_limit = 64M enable_dl = Off ; for consistency of older versions allow_call_time_pass_reference = Off html_errors = Off ; show all errors by default, if we'd lower this in the script we'll miss some parser notices error_reporting = -1 display_errors = On display_startup_errors = On log_errors = Off report_memleaks = On [Date] date.timezone = Europe/Amsterdam
Output for 5.0.0 - 5.4.45, 5.5.33, 5.6.18 - 5.6.19, 7.0.4
Warning: scandir(/etc): failed to open dir: Permission denied in /in/339h6 on line 2 Warning: scandir(): (errno 13): Permission denied in /in/339h6 on line 2 [PHP] ; Precision of floats in serialized output serialize_precision = 24 ; ini_set should be in here too if you're concerned about security disable_functions = pcntl_fork,phpinfo,mail max_execution_time = 3 memory_limit = 64M enable_dl = Off ; for consistency of older versions allow_call_time_pass_reference = Off html_errors = Off ; show all errors by default, if we'd lower this in the script we'll miss some parser notices error_reporting = -1 display_errors = On display_startup_errors = On log_errors = Off report_memleaks = On [Date] date.timezone = Europe/Amsterdam
Output for hhvm-3.12.0
Warning: Permission denied in /in/339h6 on line 2 [PHP] ; Precision of floats in serialized output serialize_precision = 24 ; ini_set should be in here too if you're concerned about security disable_functions = pcntl_fork,phpinfo,mail max_execution_time = 3 memory_limit = 64M enable_dl = Off ; for consistency of older versions allow_call_time_pass_reference = Off html_errors = Off ; show all errors by default, if we'd lower this in the script we'll miss some parser notices error_reporting = -1 display_errors = On display_startup_errors = On log_errors = Off report_memleaks = On [Date] date.timezone = Europe/Amsterdam
Output for 4.4.5 - 4.4.9
Fatal error: Call to undefined function: scandir() in /in/339h6 on line 2
Process exited with code 255.
Output for 4.3.2 - 4.4.4
Fatal error: Call to undefined function: scandir() in /in/339h6 on line 2
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Fatal error: Call to undefined function: scandir() in /in/339h6 on line 2