3v4l.org

run code in 300+ PHP versions simultaneously
<?php $items = ""; $array = array(array("tags"=>"sky - earth - sea"),array("tags"=>"iron - silver - gold"),array("tags"=>"apple - fruit - food")); foreach($array as $row) { $arr = explode(' - ', $row['tags']); $items .= "<div class='tagdown'>".implode("</div>\n<div class='tagdown'>",$arr)."</div>\n"; } echo $items;
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/cgPfT
function name:  (null)
number of ops:  21
compiled vars:  !0 = $items, !1 = $array, !2 = $row, !3 = $arr
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, ''
    4     1        ASSIGN                                                   !1, <array>
    5     2      > FE_RESET_R                                       $6      !1, ->18
          3    > > FE_FETCH_R                                               $6, !2, ->18
    6     4    >   INIT_FCALL                                               'explode'
          5        SEND_VAL                                                 '+-+'
          6        FETCH_DIM_R                                      ~7      !2, 'tags'
          7        SEND_VAL                                                 ~7
          8        DO_ICALL                                         $8      
          9        ASSIGN                                                   !3, $8
    7    10        INIT_FCALL                                               'implode'
         11        SEND_VAL                                                 '%3C%2Fdiv%3E%0A%3Cdiv+class%3D%27tagdown%27%3E'
         12        SEND_VAR                                                 !3
         13        DO_ICALL                                         $10     
         14        CONCAT                                           ~11     '%3Cdiv+class%3D%27tagdown%27%3E', $10
         15        CONCAT                                           ~12     ~11, '%3C%2Fdiv%3E%0A'
         16        ASSIGN_OP                                     8          !0, ~12
    5    17      > JMP                                                      ->3
         18    >   FE_FREE                                                  $6
    9    19        ECHO                                                     !0
   10    20      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
127.04 ms | 1400 KiB | 17 Q