3v4l.org

run code in 300+ PHP versions simultaneously
<?php function iksort($a, $b) { return strcasecmp(strtolower($a), strtolower($b)); } $testArray = array('PW_PG3_COKE_A.jpg','2DAYSALEGATE_PG2.jpg','PWBY4_DELI-1.jpg','PW_PG2_COKE_A.jpg','2DAYSALEGATE_PG1.jpg','722_PG1.jpg'); uksort($testArray, 'iksort'); print_r($testArray);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ETI1f
function name:  (null)
number of ops:  9
compiled vars:  !0 = $testArray
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   ASSIGN                                                   !0, <array>
    9     1        INIT_FCALL                                               'uksort'
          2        SEND_REF                                                 !0
          3        SEND_VAL                                                 'iksort'
          4        DO_ICALL                                                 
   10     5        INIT_FCALL                                               'print_r'
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                                 
          8      > RETURN                                                   1

Function iksort:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ETI1f
function name:  iksort
number of ops:  14
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    4     2        INIT_FCALL                                               'strcasecmp'
          3        INIT_FCALL                                               'strtolower'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $2      
          6        SEND_VAR                                                 $2
          7        INIT_FCALL                                               'strtolower'
          8        SEND_VAR                                                 !1
          9        DO_ICALL                                         $3      
         10        SEND_VAR                                                 $3
         11        DO_ICALL                                         $4      
         12      > RETURN                                                   $4
    5    13*     > RETURN                                                   null

End of function iksort

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.19 ms | 1395 KiB | 21 Q