3v4l.org

run code in 300+ PHP versions simultaneously
<?php $filename = ' <NO_MARK>9.</NO_MARK> <TI_MARK>Budjetti</TI_MARK> </MLI_OCCUR> <MLI_OCCUR NO_SEQ="010"> <NO_MARK>10.</NO_MARK> <TI_MARK>Hankintailmoituksen ennakoitu julkaisuajankohta:</TI_MARK> <TXT_MARK> <P>Lokakuu 2013.</P> </TXT_MARK> </MLI_OCCUR> <MLI_OCCUR NO_SEQ="011"> <NO_MARK>11.</NO_MARK>'; $xml_file = simplexml_load_file($filename); parseXML($xml_file->children()); function parseXML($xml_children) { foreach ($xml_children as $child){ echo $child->getName().':'. $child."<br>"; if ($child->count() > 0) { parseXML($child->children()); } } }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/33UWP
function name:  (null)
number of ops:  11
compiled vars:  !0 = $filename, !1 = $xml_file
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '%0A%3CNO_MARK%3E9.%3C%2FNO_MARK%3E%0A%3CTI_MARK%3EBudjetti%3C%2FTI_MARK%3E%0A%3C%2FMLI_OCCUR%3E%0A%3CMLI_OCCUR+NO_SEQ%3D%22010%22%3E%0A%3CNO_MARK%3E10.%3C%2FNO_MARK%3E%0A%3CTI_MARK%3EHankintailmoituksen+ennakoitu+julkaisuajankohta%3A%3C%2FTI_MARK%3E%0A%3CTXT_MARK%3E%0A%3CP%3ELokakuu+2013.%3C%2FP%3E%0A%3C%2FTXT_MARK%3E%0A%3C%2FMLI_OCCUR%3E%0A%3CMLI_OCCUR+NO_SEQ%3D%22011%22%3E%0A%3CNO_MARK%3E11.%3C%2FNO_MARK%3E'
   15     1        INIT_FCALL                                               'simplexml_load_file'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $3      
          4        ASSIGN                                                   !1, $3
   16     5        INIT_FCALL_BY_NAME                                       'parseXML'
          6        INIT_METHOD_CALL                                         !1, 'children'
          7        DO_FCALL                                      0  $5      
          8        SEND_VAR_NO_REF_EX                                       $5
          9        DO_FCALL                                      0          
   26    10      > RETURN                                                   1

Function parsexml:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 19
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 19
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 18
Branch analysis from position: 13
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 18
Branch analysis from position: 19
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 19
filename:       /in/33UWP
function name:  parseXML
number of ops:  21
compiled vars:  !0 = $xml_children, !1 = $child
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   17     0  E >   RECV                                             !0      
   19     1      > FE_RESET_R                                       $2      !0, ->19
          2    > > FE_FETCH_R                                               $2, !1, ->19
   20     3    >   INIT_METHOD_CALL                                         !1, 'getName'
          4        DO_FCALL                                      0  $3      
          5        CONCAT                                           ~4      $3, '%3A'
          6        CONCAT                                           ~5      ~4, !1
          7        CONCAT                                           ~6      ~5, '%3Cbr%3E'
          8        ECHO                                                     ~6
   21     9        INIT_METHOD_CALL                                         !1, 'count'
         10        DO_FCALL                                      0  $7      
         11        IS_SMALLER                                               0, $7
         12      > JMPZ                                                     ~8, ->18
   23    13    >   INIT_FCALL_BY_NAME                                       'parseXML'
         14        INIT_METHOD_CALL                                         !1, 'children'
         15        DO_FCALL                                      0  $9      
         16        SEND_VAR_NO_REF_EX                                       $9
         17        DO_FCALL                                      0          
   19    18    > > JMP                                                      ->2
         19    >   FE_FREE                                                  $2
   26    20      > RETURN                                                   null

End of function parsexml

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
149.12 ms | 1400 KiB | 15 Q