3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $cwd = getcwd(); mkdir($cwd . '/test'); echo directory_exists($cwd . '/test');
Output for 7.0.0 - 7.1.0
Warning: mkdir(): Permission denied in /in/9IesF on line 5 Fatal error: Uncaught Error: Call to undefined function directory_exists() in /in/9IesF:7 Stack trace: #0 {main} thrown in /in/9IesF on line 7
Process exited with code 255.
Output for 5.3.28 - 5.3.29, 5.4.18 - 5.6.28, hhvm-3.12.0
Warning: mkdir(): Permission denied in /in/9IesF on line 5 Fatal error: Call to undefined function directory_exists() in /in/9IesF on line 7
Process exited with code 255.
Output for hhvm-3.10.0

Process exited with code 153.
Output for 5.0.0 - 5.3.27, 5.4.0 - 5.4.17
Warning: mkdir(): Permission denied in /in/JQ3Fv on line 5 Fatal error: Call to undefined function directory_exists() in /in/JQ3Fv on line 7
Process exited with code 255.
Output for 4.4.5 - 4.4.9
Warning: mkdir(/in/test): Permission denied in /in/JQ3Fv on line 5 Fatal error: Call to undefined function: directory_exists() in /in/JQ3Fv on line 7
Process exited with code 255.
Output for 4.3.2 - 4.4.4
Warning: mkdir(/in/test): Permission denied in /in/JQ3Fv on line 5 Fatal error: Call to undefined function: directory_exists() in /in/JQ3Fv on line 7
Process exited with code 255.
Output for 4.3.1
Warning: mkdir(/in/test) [http://www.php.net/function.mkdir]: Permission denied in /in/JQ3Fv on line 5 Fatal error: Call to undefined function: directory_exists() in /in/JQ3Fv on line 7
Output for 4.3.0
Warning: mkdir(/in/test) [http://www.php.net/function.mkdir]: Read-only file system in /in/9IesF on line 5 Fatal error: Call to undefined function: directory_exists() in /in/9IesF on line 7