3v4l.org

run code in 300+ PHP versions simultaneously
<?php $url = 'http://stof.notk.org/'; $context = stream_context_create(array( 'http' => array('timeout' => 60) )); $fp = @fopen($url, 'r', false); if (false === $fp) { throw new Exception("Unable to connect ! "); } stream_set_blocking($fp, 1); stream_set_timeout($fp, 60); stream_socket_shutdown($fp, STREAM_SHUT_WR); $result = stream_get_contents($fp); fclose($fp); var_dump($result);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 19
Branch analysis from position: 15
1 jumps found. (Code = 108) Position 1 = -2
Branch analysis from position: 19
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/e2ZKl
function name:  (null)
number of ops:  42
compiled vars:  !0 = $url, !1 = $context, !2 = $fp, !3 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'http%3A%2F%2Fstof.notk.org%2F'
    5     1        INIT_FCALL                                               'stream_context_create'
    6     2        SEND_VAL                                                 <array>
          3        DO_ICALL                                         $5      
    5     4        ASSIGN                                                   !1, $5
    9     5        BEGIN_SILENCE                                    ~7      
          6        INIT_FCALL                                               'fopen'
          7        SEND_VAR                                                 !0
          8        SEND_VAL                                                 'r'
          9        SEND_VAL                                                 <false>
         10        DO_ICALL                                         $8      
         11        END_SILENCE                                              ~7
         12        ASSIGN                                                   !2, $8
   11    13        TYPE_CHECK                                    4          !2
         14      > JMPZ                                                     ~10, ->19
   12    15    >   NEW                                              $11     'Exception'
         16        SEND_VAL_EX                                              'Unable+to+connect+%21+'
         17        DO_FCALL                                      0          
         18      > THROW                                         0          $11
   15    19    >   INIT_FCALL                                               'stream_set_blocking'
         20        SEND_VAR                                                 !2
         21        SEND_VAL                                                 1
         22        DO_ICALL                                                 
   16    23        INIT_FCALL                                               'stream_set_timeout'
         24        SEND_VAR                                                 !2
         25        SEND_VAL                                                 60
         26        DO_ICALL                                                 
   17    27        INIT_FCALL                                               'stream_socket_shutdown'
         28        SEND_VAR                                                 !2
         29        SEND_VAL                                                 1
         30        DO_ICALL                                                 
   19    31        INIT_FCALL                                               'stream_get_contents'
         32        SEND_VAR                                                 !2
         33        DO_ICALL                                         $16     
         34        ASSIGN                                                   !3, $16
   21    35        INIT_FCALL                                               'fclose'
         36        SEND_VAR                                                 !2
         37        DO_ICALL                                                 
   23    38        INIT_FCALL                                               'var_dump'
         39        SEND_VAR                                                 !3
         40        DO_ICALL                                                 
         41      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.49 ms | 1400 KiB | 29 Q