3v4l.org

run code in 300+ PHP versions simultaneously
<?php const WEEKDAYS = ['M', 'T', 'W', 'Th', 'F', 'S', 'Su']; foreach (WEEKDAYS as $weekdayKey => $weekday) { echo '<div class="form-check form-check-inline">' . PHP_EOL . ' <input class="form-check-input" type="checkbox" id="classDays' . $weekdayKey . '" name="classDays[]" value="' . $weekday . '">' . PHP_EOL . ' <label class="form-check-label" for="classDays[]">' . PHP_EOL . ' ' . date('l', strtotime('2022-01-0' . ($weekdayKey + 3))) . PHP_EOL . ' </label>' . PHP_EOL . '</div>' . PHP_EOL; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 3, Position 2 = 30
Branch analysis from position: 3
2 jumps found. (Code = 78) Position 1 = 4, Position 2 = 30
Branch analysis from position: 4
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 30
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 30
filename:       /in/armtj
function name:  (null)
number of ops:  32
compiled vars:  !0 = $weekday, !1 = $weekdayKey
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   DECLARE_CONST                                            'WEEKDAYS', <array>
    5     1        FETCH_CONSTANT                                   ~2      'WEEKDAYS'
          2      > FE_RESET_R                                       $3      ~2, ->30
          3    > > FE_FETCH_R                                       ~4      $3, !0, ->30
          4    >   ASSIGN                                                   !1, ~4
    7     5        CONCAT                                           ~6      '%3Cdiv+class%3D%22form-check+form-check-inline%22%3E%0A++%3Cinput+class%3D%22form-check-input%22+type%3D%22checkbox%22+id%3D%22classDays', !1
          6        CONCAT                                           ~7      ~6, '%22+name%3D%22classDays%5B%5D%22+value%3D%22'
          7        CONCAT                                           ~8      ~7, !0
          8        CONCAT                                           ~9      ~8, '%22%3E'
          9        CONCAT                                           ~10     ~9, '%0A'
    8    10        CONCAT                                           ~11     ~10, '++%3Clabel+class%3D%22form-check-label%22+for%3D%22classDays%5B%5D%22%3E'
         11        CONCAT                                           ~12     ~11, '%0A'
    9    12        CONCAT                                           ~13     ~12, '++++'
         13        INIT_FCALL                                               'date'
         14        SEND_VAL                                                 'l'
         15        INIT_FCALL                                               'strtotime'
         16        ADD                                              ~14     !1, 3
         17        CONCAT                                           ~15     '2022-01-0', ~14
         18        SEND_VAL                                                 ~15
         19        DO_ICALL                                         $16     
         20        SEND_VAR                                                 $16
         21        DO_ICALL                                         $17     
         22        CONCAT                                           ~18     ~13, $17
         23        CONCAT                                           ~19     ~18, '%0A'
   10    24        CONCAT                                           ~20     ~19, '++%3C%2Flabel%3E'
         25        CONCAT                                           ~21     ~20, '%0A'
   11    26        CONCAT                                           ~22     ~21, '%3C%2Fdiv%3E'
         27        CONCAT                                           ~23     ~22, '%0A'
         28        ECHO                                                     ~23
    5    29      > JMP                                                      ->3
         30    >   FE_FREE                                                  $3
   12    31      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
143.66 ms | 1396 KiB | 17 Q