3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $fp = fsockopen("173.194.34.49", 80, $errno, $errstr, 30); if (!$fp) { echo "$errstr ($errno)<br />\n"; } else { $out = "GET / HTTP/1.1\r\n"; $out .= "Host: www.example.com\r\n"; $out .= "Connection: Close\r\n\r\n"; fwrite($fp, $out); while (!feof($fp)) { echo fgets($fp, 128); } fclose($fp); }
Output for 5.0.0 - 7.2.0
Warning: fsockopen(): unable to connect to 173.194.34.49:80 (Network is unreachable) in /in/lGG94 on line 3 Network is unreachable (101)<br />
Output for 4.3.3 - 4.4.9
Warning: fsockopen(): unable to connect to 173.194.34.49:80 in /in/lGG94 on line 3 Network is unreachable (101)<br />
Output for 4.3.2
Warning: fsockopen(): php_hostconnect: connect failed in /in/lGG94 on line 3 Warning: fsockopen(): unable to connect to 173.194.34.49:80 in /in/lGG94 on line 3 Network is unreachable (101)<br />
Output for 4.3.0 - 4.3.1

Process exited with code 139.