3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = exec("ping -n 1 -w 1 www.google.com", $input, $result); if ($result == 0){ echo "<img src=\"on.png\">"; }else{ echo "<img src=\"off.png\">"; } ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 8, Position 2 = 10
Branch analysis from position: 8
1 jumps found. (Code = 42) Position 1 = 11
Branch analysis from position: 11
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/0A7GZ
function name:  (null)
number of ops:  12
compiled vars:  !0 = $str, !1 = $input, !2 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'exec'
          1        SEND_VAL                                                 'ping+-n+1+-w+1+www.google.com'
          2        SEND_REF                                                 !1
          3        SEND_REF                                                 !2
          4        DO_ICALL                                         $3      
          5        ASSIGN                                                   !0, $3
    3     6        IS_EQUAL                                                 !2, 0
          7      > JMPZ                                                     ~5, ->10
    4     8    >   ECHO                                                     '%3Cimg+src%3D%22on.png%22%3E'
          9      > JMP                                                      ->11
    6    10    >   ECHO                                                     '%3Cimg+src%3D%22off.png%22%3E'
    8    11    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.61 ms | 1394 KiB | 15 Q