3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = '<person name="Joe Smith"> <info age="19"> <height val="1.85" /> </info> <info age="19"> <weight val="82" /> </info> <info age="19"> <build val="14" /> </info> </person>'; $xmlObj = simplexml_load_string($str); echo $xmlObj->info->attributes()->age;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/B70Ss
function name:  (null)
number of ops:  11
compiled vars:  !0 = $str, !1 = $xmlObj
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%3Cperson+name%3D%22Joe+Smith%22%3E%0A+++%3Cinfo+age%3D%2219%22%3E%0A+++++%3Cheight+val%3D%221.85%22+%2F%3E%0A+++%3C%2Finfo%3E%0A+++%3Cinfo+age%3D%2219%22%3E%0A+++++%3Cweight+val%3D%2282%22+%2F%3E%0A+++%3C%2Finfo%3E%0A+++%3Cinfo+age%3D%2219%22%3E%0A+++++%3Cbuild+val%3D%2214%22+%2F%3E%0A+++%3C%2Finfo%3E%0A%3C%2Fperson%3E'
   15     1        INIT_FCALL                                               'simplexml_load_string'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $3      
          4        ASSIGN                                                   !1, $3
   16     5        FETCH_OBJ_R                                      ~5      !1, 'info'
          6        INIT_METHOD_CALL                                         ~5, 'attributes'
          7        DO_FCALL                                      0  $6      
          8        FETCH_OBJ_R                                      ~7      $6, 'age'
          9        ECHO                                                     ~7
         10      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
196.61 ms | 1394 KiB | 15 Q