3v4l.org

run code in 300+ PHP versions simultaneously
<?php $civilIMG = '../images/avatars/civilities/docteur.png'; echo strstr(explode('/', $civilIMG)[(sizeof(explode('/', $civilIMG))-1)], '.', true);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/pXppr
function name:  (null)
number of ops:  19
compiled vars:  !0 = $civilIMG
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '..%2Fimages%2Favatars%2Fcivilities%2Fdocteur.png'
    4     1        INIT_FCALL                                               'strstr'
          2        INIT_FCALL                                               'explode'
          3        SEND_VAL                                                 '%2F'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $2      
          6        INIT_FCALL                                               'explode'
          7        SEND_VAL                                                 '%2F'
          8        SEND_VAR                                                 !0
          9        DO_ICALL                                         $3      
         10        COUNT                                            ~4      $3
         11        SUB                                              ~5      ~4, 1
         12        FETCH_DIM_R                                      ~6      $2, ~5
         13        SEND_VAL                                                 ~6
         14        SEND_VAL                                                 '.'
         15        SEND_VAL                                                 <true>
         16        DO_ICALL                                         $7      
         17        ECHO                                                     $7
         18      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
170.31 ms | 1394 KiB | 17 Q