3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $h = opendir('.'); print_r(stream_get_meta_data($h));
based on XeeDV
Output for 5.5.24 - 7.1.0
Warning: opendir(.): failed to open dir: Permission denied in /in/vWoLY on line 3 Warning: stream_get_meta_data() expects parameter 1 to be resource, boolean given in /in/vWoLY on line 6
Output for 5.2.3 - 5.4.45
Array ( [wrapper_type] => plainfile [stream_type] => dir [mode] => r [unread_bytes] => 0 [seekable] => 1 [timed_out] => [blocked] => 1 [eof] => )
Output for 4.3.2 - 5.2.2
Warning: opendir(.): failed to open dir: Permission denied in /in/vWoLY on line 3 Warning: stream_get_meta_data(): supplied argument is not a valid stream resource in /in/vWoLY on line 6
Output for 4.3.0 - 4.3.1
Warning: opendir(.) [http://www.php.net/function.opendir]: failed to open dir: Permission denied in /in/vWoLY on line 3 Warning: stream_get_meta_data(): supplied argument is not a valid stream resource in /in/vWoLY on line 6