3v4l.org

run code in 300+ PHP versions simultaneously
<?php date_default_timezone_set('America/Los_Angeles'); $currentDate = date('01-15-14'); $start = strtotime('01-12-14'); $end = strtotime('02-12-14'); $timestamp = strtotime($currentDate); if($timestamp >= $start && $timestamp <= $end) { echo $currentDate; echo "The date $currentDate is within our date range\n"; } else { echo " timestamp is $timestamp"; echo "start is $start"; echo "end is $end "; echo "The date $currentDate is NOT within our date range\n"; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 46) Position 1 = 21, Position 2 = 23
Branch analysis from position: 21
2 jumps found. (Code = 43) Position 1 = 24, Position 2 = 30
Branch analysis from position: 24
1 jumps found. (Code = 42) Position 1 = 44
Branch analysis from position: 44
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 30
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 23
filename:       /in/IfUIv
function name:  (null)
number of ops:  45
compiled vars:  !0 = $currentDate, !1 = $start, !2 = $end, !3 = $timestamp
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'date_default_timezone_set'
          1        SEND_VAL                                                 'America%2FLos_Angeles'
          2        DO_ICALL                                                 
    3     3        INIT_FCALL                                               'date'
          4        SEND_VAL                                                 '01-15-14'
          5        DO_ICALL                                         $5      
          6        ASSIGN                                                   !0, $5
    5     7        INIT_FCALL                                               'strtotime'
          8        SEND_VAL                                                 '01-12-14'
          9        DO_ICALL                                         $7      
         10        ASSIGN                                                   !1, $7
    6    11        INIT_FCALL                                               'strtotime'
         12        SEND_VAL                                                 '02-12-14'
         13        DO_ICALL                                         $9      
         14        ASSIGN                                                   !2, $9
    8    15        INIT_FCALL                                               'strtotime'
         16        SEND_VAR                                                 !0
         17        DO_ICALL                                         $11     
         18        ASSIGN                                                   !3, $11
    9    19        IS_SMALLER_OR_EQUAL                              ~13     !1, !3
         20      > JMPZ_EX                                          ~13     ~13, ->23
         21    >   IS_SMALLER_OR_EQUAL                              ~14     !3, !2
         22        BOOL                                             ~13     ~14
         23    > > JMPZ                                                     ~13, ->30
   10    24    >   ECHO                                                     !0
   11    25        ROPE_INIT                                     3  ~16     'The+date+'
         26        ROPE_ADD                                      1  ~16     ~16, !0
         27        ROPE_END                                      2  ~15     ~16, '+is+within+our+date+range%0A'
         28        ECHO                                                     ~15
         29      > JMP                                                      ->44
   13    30    >   NOP                                                      
         31        FAST_CONCAT                                      ~18     '+timestamp+is+', !3
         32        ECHO                                                     ~18
   14    33        NOP                                                      
         34        FAST_CONCAT                                      ~19     'start+is+', !1
         35        ECHO                                                     ~19
   15    36        ROPE_INIT                                     3  ~21     'end+is+'
         37        ROPE_ADD                                      1  ~21     ~21, !2
         38        ROPE_END                                      2  ~20     ~21, '+'
         39        ECHO                                                     ~20
   16    40        ROPE_INIT                                     3  ~24     'The+date+'
         41        ROPE_ADD                                      1  ~24     ~24, !0
         42        ROPE_END                                      2  ~23     ~24, '+is+NOT+within+our+date+range%0A'
         43        ECHO                                                     ~23
   17    44    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.48 ms | 1405 KiB | 19 Q