3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function fdopen($id, $mode) { return fopen("/proc/self/fd/".(int)$id, $mode); } $stdin = fopen('php://stdin', 'r'); echo $stdin; for ($i = 1; $i <= 10; $i++) { echo $i; } echo fgets(STDIN);
based on WWKTt
Output for 5.6.0 - 5.6.30, 7.0.0 - 7.2.6
Resource id #512345678910
Output for hhvm-3.15.4
Resource id #412345678910