3v4l.org

run code in 300+ PHP versions simultaneously
<?php $userfile = array( 'name' => array ( 'everybodytalkings.jpg', 'glove.png' ), 'type' => array ( 'image/jpeg', 'image/png' ), 'tmp_name' => array ( '/home/christiant.wi8/tmp/phpNmvGeZ', '/home/christiant.wi8/tmp/phpGjsRrl' ), 'error' => array ( '0', '0' ), 'size' => array ( '65188', '75182' ), ); $new = array(); foreach($userfile as $key => $item) { $new['userfile1'][] = array($key, $item[0]); $new['userfile2'][] = array($key, $item[1]); } print_r($new);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 3, Position 2 = 18
Branch analysis from position: 3
2 jumps found. (Code = 78) Position 1 = 4, Position 2 = 18
Branch analysis from position: 4
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 18
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 18
filename:       /in/5otgc
function name:  (null)
number of ops:  23
compiled vars:  !0 = $userfile, !1 = $new, !2 = $item, !3 = $key
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
   36     1        ASSIGN                                                   !1, <array>
   38     2      > FE_RESET_R                                       $6      !0, ->18
          3    > > FE_FETCH_R                                       ~7      $6, !2, ->18
          4    >   ASSIGN                                                   !3, ~7
   39     5        INIT_ARRAY                                       ~11     !3
          6        FETCH_DIM_R                                      ~12     !2, 0
          7        ADD_ARRAY_ELEMENT                                ~11     ~12
          8        FETCH_DIM_W                                      $9      !1, 'userfile1'
          9        ASSIGN_DIM                                               $9
         10        OP_DATA                                                  ~11
   40    11        INIT_ARRAY                                       ~15     !3
         12        FETCH_DIM_R                                      ~16     !2, 1
         13        ADD_ARRAY_ELEMENT                                ~15     ~16
         14        FETCH_DIM_W                                      $13     !1, 'userfile2'
         15        ASSIGN_DIM                                               $13
         16        OP_DATA                                                  ~15
   38    17      > JMP                                                      ->3
         18    >   FE_FREE                                                  $6
   43    19        INIT_FCALL                                               'print_r'
         20        SEND_VAR                                                 !1
         21        DO_ICALL                                                 
         22      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.28 ms | 1395 KiB | 15 Q