3v4l.org

run code in 500+ PHP versions simultaneously
<?php $options = ['style' => 'left']; $radios = [ 'right' => 'Right <em>(Default)</em>', 'left' => 'Left', 'fade' => 'Fade', ]; foreach ($radios as $value => $text) { printf( "<label><input type='radio' name='navbar_style[style]' value='%s'%s>%s</label>\n", $value, ($options['style'] ?? '') === $value ? ' checked' : '', $text ); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 3, Position 2 = 20
Branch analysis from position: 3
2 jumps found. (Code = 78) Position 1 = 4, Position 2 = 20
Branch analysis from position: 4
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 15
Branch analysis from position: 13
1 jumps found. (Code = 42) Position 1 = 16
Branch analysis from position: 16
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
filename:       /in/96N56m
function name:  (null)
number of ops:  22
compiled vars:  !0 = $options, !1 = $radios, !2 = $text, !3 = $value
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, <array>
    5     1        ASSIGN                                                       !1, <array>
   11     2      > FE_RESET_R                                           $6      !1, ->20
          3    > > FE_FETCH_R                                           ~7      $6, !2, ->20
          4    >   ASSIGN                                                       !3, ~7
   12     5        INIT_FCALL                                                   'printf'
   13     6        SEND_VAL                                                     '%3Clabel%3E%3Cinput+type%3D%27radio%27+name%3D%27navbar_style%5Bstyle%5D%27+value%3D%27%25s%27%25s%3E%25s%3C%2Flabel%3E%0A'
   14     7        SEND_VAR                                                     !3
   15     8        FETCH_DIM_IS                                         ~9      !0, 'style'
          9        COALESCE                                             ~10     ~9
         10        QM_ASSIGN                                            ~10     ''
         11        IS_IDENTICAL                                                 !3, ~10
         12      > JMPZ                                                         ~11, ->15
         13    >   QM_ASSIGN                                            ~12     '+checked'
         14      > JMP                                                          ->16
         15    >   QM_ASSIGN                                            ~12     ''
         16    >   SEND_VAL                                                     ~12
   16    17        SEND_VAR                                                     !2
   12    18        DO_ICALL                                                     
   11    19      > JMP                                                          ->3
         20    >   FE_FREE                                                      $6
   18    21      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
156.67 ms | 1751 KiB | 14 Q