3v4l.org

run code in 300+ PHP versions simultaneously
<?php $queryArray = array( 'ebben' => array( //$changes 'ezt' => 'erre', //No escape 'ezt2' => 'nes:erre', array( //$condition 'where' => array( 'ez' => 'ezzel' ) ) ) ); //'UPDATE _table_ SET _field_ = _value_ WHERE _field_ = _value_'; foreach($queryArray as $table => $fields) { if(array_keys($fields) !== 0) { print $table . ' SET ' . implode(' = ? ', array_keys($fields)); } }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 20
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 20
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 9, Position 2 = 19
Branch analysis from position: 9
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 19
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
filename:       /in/uXac0
function name:  (null)
number of ops:  22
compiled vars:  !0 = $queryArray, !1 = $fields, !2 = $table
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
   17     1      > FE_RESET_R                                       $4      !0, ->20
          2    > > FE_FETCH_R                                       ~5      $4, !1, ->20
          3    >   ASSIGN                                                   !2, ~5
   18     4        INIT_FCALL                                               'array_keys'
          5        SEND_VAR                                                 !1
          6        DO_ICALL                                         $7      
          7        IS_NOT_IDENTICAL                                         $7, 0
          8      > JMPZ                                                     ~8, ->19
   19     9    >   CONCAT                                           ~9      !2, '+SET+'
         10        INIT_FCALL                                               'implode'
         11        SEND_VAL                                                 '+%3D+%3F+'
         12        INIT_FCALL                                               'array_keys'
         13        SEND_VAR                                                 !1
         14        DO_ICALL                                         $10     
         15        SEND_VAR                                                 $10
         16        DO_ICALL                                         $11     
         17        CONCAT                                           ~12     ~9, $11
         18        ECHO                                                     ~12
   17    19    > > JMP                                                      ->2
         20    >   FE_FREE                                                  $4
   21    21      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.22 ms | 1395 KiB | 17 Q