3v4l.org

run code in 300+ PHP versions simultaneously
<?php $body = '<?xml version="1.0" encoding="UTF-8"?><loadTravelResponse><totalPrice>90</totalPrice></loadTravelResponse>'; $simple_xml = new \SimpleXMLElement($body); $new_total_price = $simple_xml->xpath('//totalPrice');
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/2PMQ9
function name:  (null)
number of ops:  10
compiled vars:  !0 = $body, !1 = $simple_xml, !2 = $new_total_price
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '%3C%3Fxml+version%3D%221.0%22+encoding%3D%22UTF-8%22%3F%3E%3CloadTravelResponse%3E%3CtotalPrice%3E90%3C%2FtotalPrice%3E%3C%2FloadTravelResponse%3E'
    3     1        NEW                                              $4      'SimpleXMLElement'
          2        SEND_VAR_EX                                              !0
          3        DO_FCALL                                      0          
          4        ASSIGN                                                   !1, $4
    4     5        INIT_METHOD_CALL                                         !1, 'xpath'
          6        SEND_VAL_EX                                              '%2F%2FtotalPrice'
          7        DO_FCALL                                      0  $7      
          8        ASSIGN                                                   !2, $7
          9      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
146.42 ms | 1393 KiB | 13 Q