3v4l.org

run code in 300+ PHP versions simultaneously
<?php /* +-------------------------------------------------------------+ | Copyright (c) 2015 Facebook, Inc. (http://www.facebook.com) | +-------------------------------------------------------------+ */ error_reporting(-1); ///* // $result = `dir *.*`; $result = `ls`; var_dump($result); //*/ ///* // $result = `dir *.* >dirlist.txt`; $result = `ls >dirlist.txt`; var_dump($result); unlink('dirlist.txt'); //*/ ///* $d = "dir"; $f = "*.*"; // $result = `$d {$f}`; $result = `ls`; var_dump($result); //*/ ///* $result = ``; var_dump($result); $result = ` `; var_dump($result); //*/
Output for git.master, git.master_jit, rfc.property-hooks
Warning: shell_exec(): Unable to execute 'ls' in /in/MmEm7 on line 13 bool(false) Warning: shell_exec(): Unable to execute 'ls >dirlist.txt' in /in/MmEm7 on line 19 bool(false) Warning: unlink(): open_basedir restriction in effect. File(dirlist.txt) is not within the allowed path(s): (/tmp:/in:/etc) in /in/MmEm7 on line 21 Warning: shell_exec(): Unable to execute 'ls' in /in/MmEm7 on line 28 bool(false) Fatal error: Uncaught ValueError: shell_exec(): Argument #1 ($command) cannot be empty in /in/MmEm7:33 Stack trace: #0 /in/MmEm7(33): shell_exec('') #1 {main} thrown in /in/MmEm7 on line 33
Process exited with code 255.

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
192.24 ms | 406 KiB | 5 Q