3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $fp = fopen("foo", "w"); var_dump($fp);
based on v5HSp
Output for 4.3.2 - 5.6.21, 7.0.0 - 7.1.0
Warning: fopen(foo): failed to open stream: Permission denied in /in/mTXPJ on line 3 bool(false)
Output for hhvm-3.10.0 - 3.12.0
Warning: Permission denied in /in/mTXPJ on line 3 bool(false)
Output for 4.3.1
Warning: fopen(foo) [http://www.php.net/function.fopen]: failed to create stream: Permission denied in /in/mTXPJ on line 3 bool(false)
Output for 4.3.0
Warning: fopen(foo) [http://www.php.net/function.fopen]: failed to create stream: Read-only file system in /in/mTXPJ on line 3 bool(false)