3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = "20142311.235504"; $match = array_combine(['year', 'month', 'day', 'hour', 'minute', 'second'], explode('-', (date_create_from_format("Ydm.His", $str))->format('Y-m-d-H-i-s'))); echo '<pre>', print_r($match);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/3d3vG
function name:  (null)
number of ops:  23
compiled vars:  !0 = $str, !1 = $match
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '20142311.235504'
    4     1        INIT_FCALL                                               'array_combine'
          2        SEND_VAL                                                 <array>
          3        INIT_FCALL                                               'explode'
          4        SEND_VAL                                                 '-'
          5        INIT_FCALL                                               'date_create_from_format'
          6        SEND_VAL                                                 'Ydm.His'
          7        SEND_VAR                                                 !0
          8        DO_ICALL                                         $3      
          9        INIT_METHOD_CALL                                         $3, 'format'
         10        SEND_VAL_EX                                              'Y-m-d-H-i-s'
         11        DO_FCALL                                      0  $4      
         12        SEND_VAR                                                 $4
         13        DO_ICALL                                         $5      
         14        SEND_VAR                                                 $5
         15        DO_ICALL                                         $6      
         16        ASSIGN                                                   !1, $6
    5    17        ECHO                                                     '%3Cpre%3E'
         18        INIT_FCALL                                               'print_r'
         19        SEND_VAR                                                 !1
         20        DO_ICALL                                         $8      
         21        ECHO                                                     $8
         22      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.43 ms | 1008 KiB | 17 Q