3v4l.org

run code in 300+ PHP versions simultaneously
<?php ////////// CONFIGURATION ///////////////// $ips_array=array("PC_1_NAME:172.19.144.10","PC_2_NAME:172.19.144.11","PC_3_NAME:172.19.144.10"); function ping($PC,$ip){ $cmd=shell_exec("ping -c 1 -w 200 $ip"); $dati_mount=explode(",",$cmd); if (eregi ("0", $dati_mount[1], $out)) {$connesso="<img src=\"off.gif\">";} if (eregi ("1", $dati_mount[1], $out)) {$connesso="<img src=\"on.gif\">";} $esito="$connesso [$ip] <b>$PC</b><br>"; return $esito; } while(list($k,$v)=each($ips_array)){ $dati_ip=explode(":",$v); $esito=ping($dati_ip[0],$dati_ip[1]); echo $esito; }
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Uncaught Error: Call to undefined function each() in /in/Qn2Jt:14 Stack trace: #0 {main} thrown in /in/Qn2Jt on line 14
Process exited with code 255.

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
43.6 ms | 401 KiB | 8 Q