3v4l.org

run code in 300+ PHP versions simultaneously
<?php $code = 'mdjVHcTHx04'; $data = file_get_contents('http://youtube.com/get_video_info?video_id=' . $code . '&el=vevo&fmt=18&asv=2&hd=1'); parse_str($data , $details); $my_formats_array = explode(',' , $details['adaptive_fmts']); $avail_formats[] = ''; $i = 0; $ipbits = $ip = $itag = $sig = $quality_label = ''; $expire = time(); $result[] = ''; foreach ($my_formats_array as $format) { parse_str($format); $result[$i]['quality'] = $quality_label; $type = explode(';', $type); $avail_formats[$i]['type'] = $type[0]; $avail_formats[$i]['url'] = urldecode($url); parse_str(urldecode($url)); $avail_formats[$i]['expires'] = date("G:i:s T", $expire); $avail_formats[$i]['ipbits'] = $ipbits; $avail_formats[$i]['ip'] = $ip; $time = get_duration($code); $size = get_video_size($quality_label,$time); $result[$i]['quality'] = $quality_label; $result[$i]['type'] = $type[0]; $result[$i]['size'] = $size; $result[$i]['url'] = urldecode($url); $i++; } echo json_encode($result); ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 31, Position 2 = 99
Branch analysis from position: 31
2 jumps found. (Code = 78) Position 1 = 32, Position 2 = 99
Branch analysis from position: 32
1 jumps found. (Code = 42) Position 1 = 31
Branch analysis from position: 31
Branch analysis from position: 99
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 99
filename:       /in/k5f9u
function name:  (null)
number of ops:  105
compiled vars:  !0 = $code, !1 = $data, !2 = $details, !3 = $my_formats_array, !4 = $avail_formats, !5 = $i, !6 = $ipbits, !7 = $ip, !8 = $itag, !9 = $sig, !10 = $quality_label, !11 = $expire, !12 = $result, !13 = $format, !14 = $type, !15 = $url, !16 = $time, !17 = $size
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'mdjVHcTHx04'
    4     1        INIT_FCALL                                               'file_get_contents'
          2        CONCAT                                           ~19     'http%3A%2F%2Fyoutube.com%2Fget_video_info%3Fvideo_id%3D', !0
          3        CONCAT                                           ~20     ~19, '%26el%3Dvevo%26fmt%3D18%26asv%3D2%26hd%3D1'
          4        SEND_VAL                                                 ~20
          5        DO_ICALL                                         $21     
          6        ASSIGN                                                   !1, $21
    6     7        INIT_FCALL                                               'parse_str'
          8        SEND_VAR                                                 !1
          9        SEND_REF                                                 !2
         10        DO_ICALL                                                 
    7    11        INIT_FCALL                                               'explode'
         12        SEND_VAL                                                 '%2C'
         13        FETCH_DIM_R                                      ~24     !2, 'adaptive_fmts'
         14        SEND_VAL                                                 ~24
         15        DO_ICALL                                         $25     
         16        ASSIGN                                                   !3, $25
    8    17        ASSIGN_DIM                                               !4
         18        OP_DATA                                                  ''
    9    19        ASSIGN                                                   !5, 0
   10    20        ASSIGN                                           ~29     !10, ''
         21        ASSIGN                                           ~30     !9, ~29
         22        ASSIGN                                           ~31     !8, ~30
         23        ASSIGN                                           ~32     !7, ~31
         24        ASSIGN                                                   !6, ~32
   11    25        INIT_FCALL                                               'time'
         26        DO_ICALL                                         $34     
         27        ASSIGN                                                   !11, $34
   12    28        ASSIGN_DIM                                               !12
         29        OP_DATA                                                  ''
   14    30      > FE_RESET_R                                       $37     !3, ->99
         31    > > FE_FETCH_R                                               $37, !13, ->99
   15    32    >   INIT_FCALL                                               'parse_str'
         33        SEND_VAR                                                 !13
         34        DO_ICALL                                                 
   16    35        FETCH_DIM_W                                      $39     !12, !5
         36        ASSIGN_DIM                                               $39, 'quality'
         37        OP_DATA                                                  !10
   17    38        INIT_FCALL                                               'explode'
         39        SEND_VAL                                                 '%3B'
         40        SEND_VAR                                                 !14
         41        DO_ICALL                                         $41     
         42        ASSIGN                                                   !14, $41
   18    43        FETCH_DIM_R                                      ~45     !14, 0
         44        FETCH_DIM_W                                      $43     !4, !5
         45        ASSIGN_DIM                                               $43, 'type'
         46        OP_DATA                                                  ~45
   19    47        INIT_FCALL                                               'urldecode'
         48        SEND_VAR                                                 !15
         49        DO_ICALL                                         $48     
         50        FETCH_DIM_W                                      $46     !4, !5
         51        ASSIGN_DIM                                               $46, 'url'
         52        OP_DATA                                                  $48
   20    53        INIT_FCALL                                               'parse_str'
         54        INIT_FCALL                                               'urldecode'
         55        SEND_VAR                                                 !15
         56        DO_ICALL                                         $49     
         57        SEND_VAR                                                 $49
         58        DO_ICALL                                                 
   21    59        INIT_FCALL                                               'date'
         60        SEND_VAL                                                 'G%3Ai%3As+T'
         61        SEND_VAR                                                 !11
         62        DO_ICALL                                         $53     
         63        FETCH_DIM_W                                      $51     !4, !5
         64        ASSIGN_DIM                                               $51, 'expires'
         65        OP_DATA                                                  $53
   22    66        FETCH_DIM_W                                      $54     !4, !5
         67        ASSIGN_DIM                                               $54, 'ipbits'
         68        OP_DATA                                                  !6
   23    69        FETCH_DIM_W                                      $56     !4, !5
         70        ASSIGN_DIM                                               $56, 'ip'
         71        OP_DATA                                                  !7
   25    72        INIT_FCALL_BY_NAME                                       'get_duration'
         73        SEND_VAR_EX                                              !0
         74        DO_FCALL                                      0  $58     
         75        ASSIGN                                                   !16, $58
   26    76        INIT_FCALL_BY_NAME                                       'get_video_size'
         77        SEND_VAR_EX                                              !10
         78        SEND_VAR_EX                                              !16
         79        DO_FCALL                                      0  $60     
         80        ASSIGN                                                   !17, $60
   28    81        FETCH_DIM_W                                      $62     !12, !5
         82        ASSIGN_DIM                                               $62, 'quality'
         83        OP_DATA                                                  !10
   29    84        FETCH_DIM_R                                      ~66     !14, 0
         85        FETCH_DIM_W                                      $64     !12, !5
         86        ASSIGN_DIM                                               $64, 'type'
         87        OP_DATA                                                  ~66
   30    88        FETCH_DIM_W                                      $67     !12, !5
         89        ASSIGN_DIM                                               $67, 'size'
         90        OP_DATA                                                  !17
   31    91        INIT_FCALL                                               'urldecode'
         92        SEND_VAR                                                 !15
         93        DO_ICALL                                         $71     
         94        FETCH_DIM_W                                      $69     !12, !5
         95        ASSIGN_DIM                                               $69, 'url'
         96        OP_DATA                                                  $71
   33    97        PRE_INC                                                  !5
   14    98      > JMP                                                      ->31
         99    >   FE_FREE                                                  $37
   35   100        INIT_FCALL                                               'json_encode'
        101        SEND_VAR                                                 !12
        102        DO_ICALL                                         $73     
        103        ECHO                                                     $73
   36   104      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.57 ms | 1404 KiB | 27 Q