3v4l.org

run code in 300+ PHP versions simultaneously
<?php $startDate = "2015-08-01"; $endDate = "2015-08-31"; $startDate = strtotime($startDate); $endDate = strtotime($endDate); for($i = strtotime('Friday', $startDate); $i <= $endDate; $i = strtotime('+1 week', $i)) echo date('l Y-m-d', $i);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 26
Branch analysis from position: 26
2 jumps found. (Code = 44) Position 1 = 28, Position 2 = 16
Branch analysis from position: 28
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 16
2 jumps found. (Code = 44) Position 1 = 28, Position 2 = 16
Branch analysis from position: 28
Branch analysis from position: 16
filename:       /in/jFG9j
function name:  (null)
number of ops:  29
compiled vars:  !0 = $startDate, !1 = $endDate, !2 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '2015-08-01'
    3     1        ASSIGN                                                   !1, '2015-08-31'
    5     2        INIT_FCALL                                               'strtotime'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                         $5      
          5        ASSIGN                                                   !0, $5
    6     6        INIT_FCALL                                               'strtotime'
          7        SEND_VAR                                                 !1
          8        DO_ICALL                                         $7      
          9        ASSIGN                                                   !1, $7
    8    10        INIT_FCALL                                               'strtotime'
         11        SEND_VAL                                                 'Friday'
         12        SEND_VAR                                                 !0
         13        DO_ICALL                                         $9      
         14        ASSIGN                                                   !2, $9
         15      > JMP                                                      ->26
    9    16    >   INIT_FCALL                                               'date'
         17        SEND_VAL                                                 'l+Y-m-d'
         18        SEND_VAR                                                 !2
         19        DO_ICALL                                         $11     
         20        ECHO                                                     $11
    8    21        INIT_FCALL                                               'strtotime'
         22        SEND_VAL                                                 '%2B1+week'
         23        SEND_VAR                                                 !2
         24        DO_ICALL                                         $12     
         25        ASSIGN                                                   !2, $12
         26    >   IS_SMALLER_OR_EQUAL                                      !2, !1
         27      > JMPNZ                                                    ~14, ->16
    9    28    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
204.83 ms | 1396 KiB | 17 Q