3v4l.org

run code in 300+ PHP versions simultaneously
<?php $request = xmlrpc_encode_request("method", array(1, 2, 3)); $context = stream_context_create(array('http' => array( 'method' => "POST", 'header' => "Content-Type: text/xml", 'content' => $request ))); $file = file_get_contents("http://www.example.com/xmlrpc", false, $context); $response = xmlrpc_decode($file); if ($response && xmlrpc_is_fault($response)) { trigger_error("xmlrpc: $response[faultString] ($response[faultCode])"); } else { print_r($response); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 46) Position 1 = 24, Position 2 = 28
Branch analysis from position: 24
2 jumps found. (Code = 43) Position 1 = 29, Position 2 = 40
Branch analysis from position: 29
1 jumps found. (Code = 42) Position 1 = 43
Branch analysis from position: 43
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 40
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 28
filename:       /in/E4mjI
function name:  (null)
number of ops:  44
compiled vars:  !0 = $request, !1 = $context, !2 = $file, !3 = $response
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL_BY_NAME                                       'xmlrpc_encode_request'
          1        SEND_VAL_EX                                              'method'
          2        SEND_VAL_EX                                              <array>
          3        DO_FCALL                                      0  $4      
          4        ASSIGN                                                   !0, $4
    3     5        INIT_FCALL                                               'stream_context_create'
    4     6        INIT_ARRAY                                       ~6      'POST', 'method'
    5     7        ADD_ARRAY_ELEMENT                                ~6      'Content-Type%3A+text%2Fxml', 'header'
    6     8        ADD_ARRAY_ELEMENT                                ~6      !0, 'content'
          9        INIT_ARRAY                                       ~7      ~6, 'http'
         10        SEND_VAL                                                 ~7
         11        DO_ICALL                                         $8      
    3    12        ASSIGN                                                   !1, $8
    8    13        INIT_FCALL                                               'file_get_contents'
         14        SEND_VAL                                                 'http%3A%2F%2Fwww.example.com%2Fxmlrpc'
         15        SEND_VAL                                                 <false>
         16        SEND_VAR                                                 !1
         17        DO_ICALL                                         $10     
         18        ASSIGN                                                   !2, $10
    9    19        INIT_FCALL_BY_NAME                                       'xmlrpc_decode'
         20        SEND_VAR_EX                                              !2
         21        DO_FCALL                                      0  $12     
         22        ASSIGN                                                   !3, $12
   10    23      > JMPZ_EX                                          ~14     !3, ->28
         24    >   INIT_FCALL_BY_NAME                                       'xmlrpc_is_fault'
         25        SEND_VAR_EX                                              !3
         26        DO_FCALL                                      0  $15     
         27        BOOL                                             ~14     $15
         28    > > JMPZ                                                     ~14, ->40
   11    29    >   INIT_FCALL                                               'trigger_error'
         30        ROPE_INIT                                     5  ~19     'xmlrpc%3A+'
         31        FETCH_DIM_R                                      ~16     !3, 'faultString'
         32        ROPE_ADD                                      1  ~19     ~19, ~16
         33        ROPE_ADD                                      2  ~19     ~19, '+%28'
         34        FETCH_DIM_R                                      ~17     !3, 'faultCode'
         35        ROPE_ADD                                      3  ~19     ~19, ~17
         36        ROPE_END                                      4  ~18     ~19, '%29'
         37        SEND_VAL                                                 ~18
         38        DO_ICALL                                                 
         39      > JMP                                                      ->43
   13    40    >   INIT_FCALL                                               'print_r'
         41        SEND_VAR                                                 !3
         42        DO_ICALL                                                 
   14    43    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
147.13 ms | 1400 KiB | 21 Q