3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php if ($handle = opendir('/in/s3tYl')) { echo "Directory handle: $handle\n"; echo "Entries:\n"; /* This is the correct way to loop over the directory. */ while (false !== ($entry = readdir($handle))) { echo "$entry\n"; } /* This is the WRONG way to loop over the directory. */ while ($entry = readdir($handle)) { echo "$entry\n"; } closedir($handle); }
Output for 4.3.2 - 5.6.28, 7.0.0 - 7.1.0
Warning: opendir(/in/s3tYl): failed to open dir: No such file or directory in /in/RbBVA on line 2
Output for hhvm-3.10.0 - 3.12.0
Warning: No such file or directory in /in/RbBVA on line 2
Output for 4.3.0 - 4.3.1
Warning: opendir(/in/s3tYl) [http://www.php.net/function.opendir]: failed to open dir: No such file or directory in /in/RbBVA on line 2