3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $h = fopen("http://173.194.45.87", 'r'); while($line = fgets($h)) { printf("line = '%s'.\n", $line); }
Output for 5.3.0 - 7.1.0
Warning: fopen(http://173.194.45.87): failed to open stream: Network is unreachable in /in/7TbIk on line 2 Warning: fgets() expects parameter 1 to be resource, boolean given in /in/7TbIk on line 4
Output for 4.3.3 - 5.2.17
Warning: fopen(http://173.194.45.87): failed to open stream: Network is unreachable in /in/7TbIk on line 2 Warning: fgets(): supplied argument is not a valid stream resource in /in/7TbIk on line 4
Output for 4.3.2
Warning: fopen(): php_hostconnect: connect failed in /in/7TbIk on line 2 Warning: fopen(http://173.194.45.87): failed to open stream: Network is unreachable in /in/7TbIk on line 2 Warning: fgets(): supplied argument is not a valid stream resource in /in/7TbIk on line 4
Output for 4.3.0 - 4.3.1
Warning: fopen() [http://www.php.net/function.fopen]: php_hostconnect: connect failed in /in/7TbIk on line 2 Warning: fopen(http://173.194.45.87) [http://www.php.net/function.fopen]: failed to create stream: Network is unreachable in /in/7TbIk on line 2 Warning: fgets(): supplied argument is not a valid stream resource in /in/7TbIk on line 4