3v4l.org

run code in 300+ PHP versions simultaneously
<?php $url = "http://maps.googleapis.com/maps/api/distancematrix/json?origins=Bangu+RJ&destinations=Centro+RJ&mode=driving&language=pt-BR&sensor=false"; $json = file_get_contents($url); $data = json_decode($json); print $data->elements->distance->{'text'}; ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/h71ms
function name:  (null)
number of ops:  14
compiled vars:  !0 = $url, !1 = $json, !2 = $data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'http%3A%2F%2Fmaps.googleapis.com%2Fmaps%2Fapi%2Fdistancematrix%2Fjson%3Forigins%3DBangu%2BRJ%26destinations%3DCentro%2BRJ%26mode%3Ddriving%26language%3Dpt-BR%26sensor%3Dfalse'
    5     1        INIT_FCALL                                               'file_get_contents'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $4      
          4        ASSIGN                                                   !1, $4
    6     5        INIT_FCALL                                               'json_decode'
          6        SEND_VAR                                                 !1
          7        DO_ICALL                                         $6      
          8        ASSIGN                                                   !2, $6
    8     9        FETCH_OBJ_R                                      ~8      !2, 'elements'
         10        FETCH_OBJ_R                                      ~9      ~8, 'distance'
         11        FETCH_OBJ_R                                      ~10     ~9, 'text'
         12        ECHO                                                     ~10
   10    13      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.11 ms | 1398 KiB | 17 Q