3v4l.org

run code in 300+ PHP versions simultaneously
<?php /** * Fetch YouTube data from ID * @param string $id YouTube ID: http://youtube.com/watch?v=[ID] (es: http://youtube.com/watch?v=ik1PUh5GO3g) * @return array */ function get_youtube_data($id) { $data = file_get_contents('http://www.youtube.com/get_video_info?&video_id=' . $id); parse_str($data, $data); return $data; } $t = get_youtube_data('ik1PUh5GO3g');
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/750mo
function name:  (null)
number of ops:  5
compiled vars:  !0 = $t
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   16     0  E >   INIT_FCALL                                               'get_youtube_data'
          1        SEND_VAL                                                 'ik1PUh5GO3g'
          2        DO_FCALL                                      0  $1      
          3        ASSIGN                                                   !0, $1
          4      > RETURN                                                   1

Function get_youtube_data:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/750mo
function name:  get_youtube_data
number of ops:  12
compiled vars:  !0 = $id, !1 = $data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   RECV                                             !0      
   10     1        INIT_FCALL                                               'file_get_contents'
          2        CONCAT                                           ~2      'http%3A%2F%2Fwww.youtube.com%2Fget_video_info%3F%26video_id%3D', !0
          3        SEND_VAL                                                 ~2
          4        DO_ICALL                                         $3      
          5        ASSIGN                                                   !1, $3
   11     6        INIT_FCALL                                               'parse_str'
          7        SEND_VAR                                                 !1
          8        SEND_REF                                                 !1
          9        DO_ICALL                                                 
   13    10      > RETURN                                                   !1
   14    11*     > RETURN                                                   null

End of function get_youtube_data

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
168.39 ms | 1397 KiB | 18 Q