3v4l.org

run code in 300+ PHP versions simultaneously
<?php $related = array(1,2,3); $sql = "SELECT id,title,pic1 FROM tbl_products WHERE id IN ("; $questionmarks = ""; for($i=0;$i<count($related);$i++) { $questionmarks .= "?,"; } $sql .= trim($questionmarks,","); $sql .= ") LIMIT 3;"; echo $sql;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 7
Branch analysis from position: 7
2 jumps found. (Code = 44) Position 1 = 10, Position 2 = 5
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
2 jumps found. (Code = 44) Position 1 = 10, Position 2 = 5
Branch analysis from position: 10
Branch analysis from position: 5
filename:       /in/No4h1
function name:  (null)
number of ops:  18
compiled vars:  !0 = $related, !1 = $sql, !2 = $questionmarks, !3 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        ASSIGN                                                   !1, 'SELECT+id%2Ctitle%2Cpic1+FROM+tbl_products+WHERE+id+IN+%28'
    5     2        ASSIGN                                                   !2, ''
    7     3        ASSIGN                                                   !3, 0
          4      > JMP                                                      ->7
    9     5    >   ASSIGN_OP                                     8          !2, '%3F%2C'
    7     6        PRE_INC                                                  !3
          7    >   COUNT                                            ~10     !0
          8        IS_SMALLER                                               !3, ~10
          9      > JMPNZ                                                    ~11, ->5
   12    10    >   INIT_FCALL                                               'trim'
         11        SEND_VAR                                                 !2
         12        SEND_VAL                                                 '%2C'
         13        DO_ICALL                                         $12     
         14        ASSIGN_OP                                     8          !1, $12
   14    15        ASSIGN_OP                                     8          !1, '%29+LIMIT+3%3B'
   17    16        ECHO                                                     !1
         17      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
124.14 ms | 999 KiB | 14 Q