3v4l.org

run code in 300+ PHP versions simultaneously
<?php $interval = "00:00-23:59"; $pickup_time = "2014-05-08 23:58:00"; $interval = explode("-",$interval); $start = str_replace (":", "", $interval[0]); $end = str_replace (":", "", $interval[1]); $pickup_time = (int) date('Gi', strtotime($pickup_time)); if ($pickup_time >= $start && $pickup_time <= $end ){ return true; }else{ return false; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 46) Position 1 = 32, Position 2 = 34
Branch analysis from position: 32
2 jumps found. (Code = 43) Position 1 = 35, Position 2 = 37
Branch analysis from position: 35
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 37
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 34
filename:       /in/WZs48
function name:  (null)
number of ops:  39
compiled vars:  !0 = $interval, !1 = $pickup_time, !2 = $start, !3 = $end
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '00%3A00-23%3A59'
    3     1        ASSIGN                                                   !1, '2014-05-08+23%3A58%3A00'
    5     2        INIT_FCALL                                               'explode'
          3        SEND_VAL                                                 '-'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $6      
          6        ASSIGN                                                   !0, $6
    6     7        INIT_FCALL                                               'str_replace'
          8        SEND_VAL                                                 '%3A'
          9        SEND_VAL                                                 ''
         10        FETCH_DIM_R                                      ~8      !0, 0
         11        SEND_VAL                                                 ~8
         12        DO_ICALL                                         $9      
         13        ASSIGN                                                   !2, $9
    7    14        INIT_FCALL                                               'str_replace'
         15        SEND_VAL                                                 '%3A'
         16        SEND_VAL                                                 ''
         17        FETCH_DIM_R                                      ~11     !0, 1
         18        SEND_VAL                                                 ~11
         19        DO_ICALL                                         $12     
         20        ASSIGN                                                   !3, $12
    9    21        INIT_FCALL                                               'date'
         22        SEND_VAL                                                 'Gi'
         23        INIT_FCALL                                               'strtotime'
         24        SEND_VAR                                                 !1
         25        DO_ICALL                                         $14     
         26        SEND_VAR                                                 $14
         27        DO_ICALL                                         $15     
         28        CAST                                          4  ~16     $15
         29        ASSIGN                                                   !1, ~16
   11    30        IS_SMALLER_OR_EQUAL                              ~18     !2, !1
         31      > JMPZ_EX                                          ~18     ~18, ->34
         32    >   IS_SMALLER_OR_EQUAL                              ~19     !1, !3
         33        BOOL                                             ~18     ~19
         34    > > JMPZ                                                     ~18, ->37
   12    35    > > RETURN                                                   <true>
         36*       JMP                                                      ->38
   14    37    > > RETURN                                                   <false>
   15    38*     > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.06 ms | 1396 KiB | 21 Q