3v4l.org

run code in 300+ PHP versions simultaneously
<?php $city = array(); $city[1] = "'Paris'"; $city[2] = "'London'"; $cityString= implode(", ", $city); echo "SELECT * FROM Customers WHERE City IN ($cityString);";
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/dcbRB
function name:  (null)
number of ops:  15
compiled vars:  !0 = $city, !1 = $cityString
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        ASSIGN_DIM                                               !0, 1
          2        OP_DATA                                                  '%27Paris%27'
    5     3        ASSIGN_DIM                                               !0, 2
          4        OP_DATA                                                  '%27London%27'
    6     5        INIT_FCALL                                               'implode'
          6        SEND_VAL                                                 '%2C+'
          7        SEND_VAR                                                 !0
          8        DO_ICALL                                         $5      
          9        ASSIGN                                                   !1, $5
    8    10        ROPE_INIT                                     3  ~8      'SELECT+%2A+FROM+Customers%0AWHERE+City+IN+%28'
    9    11        ROPE_ADD                                      1  ~8      ~8, !1
         12        ROPE_END                                      2  ~7      ~8, '%29%3B'
         13        ECHO                                                     ~7
         14      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.17 ms | 1394 KiB | 15 Q