3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $resource = fopen('php://input'); var_dump((string)$resource, gettype($resource)); fclose($resource); var_dump((string)$resource, gettype($resource));
Output for 5.3.0 - 7.1.0
Warning: fopen() expects at least 2 parameters, 1 given in /in/SVpnI on line 3 string(0) "" string(7) "boolean" Warning: fclose() expects parameter 1 to be resource, boolean given in /in/SVpnI on line 5 string(0) "" string(7) "boolean"
Output for 4.3.0 - 5.2.17
Warning: fopen() expects at least 2 parameters, 1 given in /in/SVpnI on line 3 string(0) "" string(7) "boolean" Warning: fclose(): supplied argument is not a valid stream resource in /in/SVpnI on line 5 string(0) "" string(7) "boolean"