3v4l.org

run code in 300+ PHP versions simultaneously
<?php $urlparts = parse_url("http://www.domain.com/somefolder/index.html"); $extracted = $urlparts['path']; echo ltrim($extracted, '/');
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/W7t0M
function name:  (null)
number of ops:  12
compiled vars:  !0 = $urlparts, !1 = $extracted
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'parse_url'
          1        SEND_VAL                                                 'http%3A%2F%2Fwww.domain.com%2Fsomefolder%2Findex.html'
          2        DO_ICALL                                         $2      
          3        ASSIGN                                                   !0, $2
    3     4        FETCH_DIM_R                                      ~4      !0, 'path'
          5        ASSIGN                                                   !1, ~4
    4     6        INIT_FCALL                                               'ltrim'
          7        SEND_VAR                                                 !1
          8        SEND_VAL                                                 '%2F'
          9        DO_ICALL                                         $6      
         10        ECHO                                                     $6
         11      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
146.31 ms | 1394 KiB | 17 Q