3v4l.org

run code in 300+ PHP versions simultaneously
<?php $time = strtotime(date('Y-m').'-01'); echo date('Y-m-d',$time); echo '<br>'.$final = date("Y-t-d", strtotime("-1 month", $time)); echo date('m-01-Y 00:00:00',strtotime('this month')) . '<br/>'; echo date('m-t-Y 12:59:59',strtotime('this month')) . '<br/>'; echo '<br>'.$current_month_start_day = strtotime(date('Y-m').'-01'); echo '<br>'.$prev_month_start_day = date("d.m.Y", strtotime("-1 month", $current_month_start_day)); echo '<br>'.$_REQUEST['date_start'] = $prev_month_start_day; // 01.12.2013 echo '<br>'.$_EQUEST['date_end'] = date("t.m.Y", strtotime("-1 month", $current_month_start_day)); // 31.12.2013 echo '-----------------'; $current_month_start_day = strtotime(date('Y-m') . '-01'); echo '<br>'.$_REQUEST['date_start'] = date("d.m.Y", strtotime("-1 month", $current_month_start_day)); // 01.12.2013 echo '<br>'.$_REQUEST['date_end'] = date("t.m.Y", strtotime("-1 month", $current_month_start_day)); // 31.12.2013
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/KDXJR
function name:  (null)
number of ops:  116
compiled vars:  !0 = $time, !1 = $final, !2 = $current_month_start_day, !3 = $prev_month_start_day, !4 = $_EQUEST
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'strtotime'
          1        INIT_FCALL                                               'date'
          2        SEND_VAL                                                 'Y-m'
          3        DO_ICALL                                         $5      
          4        CONCAT                                           ~6      $5, '-01'
          5        SEND_VAL                                                 ~6
          6        DO_ICALL                                         $7      
          7        ASSIGN                                                   !0, $7
    3     8        INIT_FCALL                                               'date'
          9        SEND_VAL                                                 'Y-m-d'
         10        SEND_VAR                                                 !0
         11        DO_ICALL                                         $9      
         12        ECHO                                                     $9
    4    13        INIT_FCALL                                               'date'
         14        SEND_VAL                                                 'Y-t-d'
         15        INIT_FCALL                                               'strtotime'
         16        SEND_VAL                                                 '-1+month'
         17        SEND_VAR                                                 !0
         18        DO_ICALL                                         $10     
         19        SEND_VAR                                                 $10
         20        DO_ICALL                                         $11     
         21        ASSIGN                                           ~12     !1, $11
         22        CONCAT                                           ~13     '%3Cbr%3E', ~12
         23        ECHO                                                     ~13
    6    24        INIT_FCALL                                               'date'
         25        SEND_VAL                                                 'm-01-Y+00%3A00%3A00'
         26        INIT_FCALL                                               'strtotime'
         27        SEND_VAL                                                 'this+month'
         28        DO_ICALL                                         $14     
         29        SEND_VAR                                                 $14
         30        DO_ICALL                                         $15     
         31        CONCAT                                           ~16     $15, '%3Cbr%2F%3E'
         32        ECHO                                                     ~16
    7    33        INIT_FCALL                                               'date'
         34        SEND_VAL                                                 'm-t-Y+12%3A59%3A59'
         35        INIT_FCALL                                               'strtotime'
         36        SEND_VAL                                                 'this+month'
         37        DO_ICALL                                         $17     
         38        SEND_VAR                                                 $17
         39        DO_ICALL                                         $18     
         40        CONCAT                                           ~19     $18, '%3Cbr%2F%3E'
         41        ECHO                                                     ~19
   10    42        INIT_FCALL                                               'strtotime'
         43        INIT_FCALL                                               'date'
         44        SEND_VAL                                                 'Y-m'
         45        DO_ICALL                                         $20     
         46        CONCAT                                           ~21     $20, '-01'
         47        SEND_VAL                                                 ~21
         48        DO_ICALL                                         $22     
         49        ASSIGN                                           ~23     !2, $22
         50        CONCAT                                           ~24     '%3Cbr%3E', ~23
         51        ECHO                                                     ~24
   11    52        INIT_FCALL                                               'date'
         53        SEND_VAL                                                 'd.m.Y'
         54        INIT_FCALL                                               'strtotime'
         55        SEND_VAL                                                 '-1+month'
         56        SEND_VAR                                                 !2
         57        DO_ICALL                                         $25     
         58        SEND_VAR                                                 $25
         59        DO_ICALL                                         $26     
         60        ASSIGN                                           ~27     !3, $26
         61        CONCAT                                           ~28     '%3Cbr%3E', ~27
         62        ECHO                                                     ~28
   13    63        FETCH_W                      global              $29     '_REQUEST'
         64        ASSIGN_DIM                                       ~30     $29, 'date_start'
         65        OP_DATA                                                  !3
         66        CONCAT                                           ~31     '%3Cbr%3E', ~30
         67        ECHO                                                     ~31
   14    68        INIT_FCALL                                               'date'
         69        SEND_VAL                                                 't.m.Y'
         70        INIT_FCALL                                               'strtotime'
         71        SEND_VAL                                                 '-1+month'
         72        SEND_VAR                                                 !2
         73        DO_ICALL                                         $33     
         74        SEND_VAR                                                 $33
         75        DO_ICALL                                         $34     
         76        ASSIGN_DIM                                       ~32     !4, 'date_end'
         77        OP_DATA                                                  $34
         78        CONCAT                                           ~35     '%3Cbr%3E', ~32
         79        ECHO                                                     ~35
   16    80        ECHO                                                     '-----------------'
   18    81        INIT_FCALL                                               'strtotime'
         82        INIT_FCALL                                               'date'
         83        SEND_VAL                                                 'Y-m'
         84        DO_ICALL                                         $36     
         85        CONCAT                                           ~37     $36, '-01'
         86        SEND_VAL                                                 ~37
         87        DO_ICALL                                         $38     
         88        ASSIGN                                                   !2, $38
   19    89        INIT_FCALL                                               'date'
         90        SEND_VAL                                                 'd.m.Y'
         91        INIT_FCALL                                               'strtotime'
         92        SEND_VAL                                                 '-1+month'
         93        SEND_VAR                                                 !2
         94        DO_ICALL                                         $42     
         95        SEND_VAR                                                 $42
         96        DO_ICALL                                         $43     
         97        FETCH_W                      global              $40     '_REQUEST'
         98        ASSIGN_DIM                                       ~41     $40, 'date_start'
         99        OP_DATA                                                  $43
        100        CONCAT                                           ~44     '%3Cbr%3E', ~41
        101        ECHO                                                     ~44
   20   102        INIT_FCALL                                               'date'
        103        SEND_VAL                                                 't.m.Y'
        104        INIT_FCALL                                               'strtotime'
        105        SEND_VAL                                                 '-1+month'
        106        SEND_VAR                                                 !2
        107        DO_ICALL                                         $47     
        108        SEND_VAR                                                 $47
        109        DO_ICALL                                         $48     
        110        FETCH_W                      global              $45     '_REQUEST'
        111        ASSIGN_DIM                                       ~46     $45, 'date_end'
        112        OP_DATA                                                  $48
        113        CONCAT                                           ~49     '%3Cbr%3E', ~46
        114        ECHO                                                     ~49
        115      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
161.03 ms | 1404 KiB | 17 Q