3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = "{\"url\":\"http:\/\/treadmills.findthebest.com\/l\/230\/LifeSpan-TR5000i\"}"; $json = json_decode($str); echo $json->url; $parts=parse_url($json->url); echo $parts['path']; $array = explode('/',$parts['path']); var_dump($array); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/RXnvQ
function name:  (null)
number of ops:  24
compiled vars:  !0 = $str, !1 = $json, !2 = $parts, !3 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '%7B%22url%22%3A%22http%3A%5C%2F%5C%2Ftreadmills.findthebest.com%5C%2Fl%5C%2F230%5C%2FLifeSpan-TR5000i%22%7D'
    4     1        INIT_FCALL                                               'json_decode'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $5      
          4        ASSIGN                                                   !1, $5
    5     5        FETCH_OBJ_R                                      ~7      !1, 'url'
          6        ECHO                                                     ~7
    6     7        INIT_FCALL                                               'parse_url'
          8        FETCH_OBJ_R                                      ~8      !1, 'url'
          9        SEND_VAL                                                 ~8
         10        DO_ICALL                                         $9      
         11        ASSIGN                                                   !2, $9
    7    12        FETCH_DIM_R                                      ~11     !2, 'path'
         13        ECHO                                                     ~11
    8    14        INIT_FCALL                                               'explode'
         15        SEND_VAL                                                 '%2F'
         16        FETCH_DIM_R                                      ~12     !2, 'path'
         17        SEND_VAL                                                 ~12
         18        DO_ICALL                                         $13     
         19        ASSIGN                                                   !3, $13
    9    20        INIT_FCALL                                               'var_dump'
         21        SEND_VAR                                                 !3
         22        DO_ICALL                                                 
   10    23      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.64 ms | 1395 KiB | 21 Q