3v4l.org

run code in 300+ PHP versions simultaneously
<?php $ch = curl_init (); $data=array( 'affiliate_id'=>'A0000000003', 'type' => 'lost', 'damage_value' => 1.50, 'shipping_date' => '2013-11-11', 'item_name'=>'test_product', 'shipping_country'=>'Burbank', 'description' => 'Missing 2 out of 3 parts', 'billing_country'=>'US', 'email'=>'tim@insureship.com', 'firstname'=>'Johana', 'lastname'=>'Velez' ); $api_url='https://int.insureship.com/api/claims/submit/00002'; curl_setopt($ch, CURLOPT_USERPWD,"test2:password"); curl_setopt ( $ch, CURLOPT_URL, $api_url ); curl_setopt ( $ch, CURLOPT_HEADER, true ); curl_setopt ( $ch, CURLOPT_POST, true ); curl_setopt ( $ch, CURLOPT_POSTFIELDS, $data ); curl_setopt ( $ch, CURLOPT_RETURNTRANSFER, true); curl_setopt( $ch,CURLOPT_HTTPHEADER,array ("Accept:application/json")); $result = curl_exec ($ch);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/fkH1H
function name:  (null)
number of ops:  52
compiled vars:  !0 = $ch, !1 = $data, !2 = $api_url, !3 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL_BY_NAME                                       'curl_init'
          1        DO_FCALL                                      0  $4      
          2        ASSIGN                                                   !0, $4
    4     3        ASSIGN                                                   !1, <array>
   17     4        ASSIGN                                                   !2, 'https%3A%2F%2Fint.insureship.com%2Fapi%2Fclaims%2Fsubmit%2F00002'
   18     5        INIT_FCALL_BY_NAME                                       'curl_setopt'
          6        SEND_VAR_EX                                              !0
          7        FETCH_CONSTANT                                   ~8      'CURLOPT_USERPWD'
          8        SEND_VAL_EX                                              ~8
          9        SEND_VAL_EX                                              'test2%3Apassword'
         10        DO_FCALL                                      0          
   19    11        INIT_FCALL_BY_NAME                                       'curl_setopt'
         12        SEND_VAR_EX                                              !0
         13        FETCH_CONSTANT                                   ~10     'CURLOPT_URL'
         14        SEND_VAL_EX                                              ~10
         15        SEND_VAR_EX                                              !2
         16        DO_FCALL                                      0          
   20    17        INIT_FCALL_BY_NAME                                       'curl_setopt'
         18        SEND_VAR_EX                                              !0
         19        FETCH_CONSTANT                                   ~12     'CURLOPT_HEADER'
         20        SEND_VAL_EX                                              ~12
         21        SEND_VAL_EX                                              <true>
         22        DO_FCALL                                      0          
   21    23        INIT_FCALL_BY_NAME                                       'curl_setopt'
         24        SEND_VAR_EX                                              !0
         25        FETCH_CONSTANT                                   ~14     'CURLOPT_POST'
         26        SEND_VAL_EX                                              ~14
         27        SEND_VAL_EX                                              <true>
         28        DO_FCALL                                      0          
   22    29        INIT_FCALL_BY_NAME                                       'curl_setopt'
         30        SEND_VAR_EX                                              !0
         31        FETCH_CONSTANT                                   ~16     'CURLOPT_POSTFIELDS'
         32        SEND_VAL_EX                                              ~16
         33        SEND_VAR_EX                                              !1
         34        DO_FCALL                                      0          
   23    35        INIT_FCALL_BY_NAME                                       'curl_setopt'
         36        SEND_VAR_EX                                              !0
         37        FETCH_CONSTANT                                   ~18     'CURLOPT_RETURNTRANSFER'
         38        SEND_VAL_EX                                              ~18
         39        SEND_VAL_EX                                              <true>
         40        DO_FCALL                                      0          
   24    41        INIT_FCALL_BY_NAME                                       'curl_setopt'
         42        SEND_VAR_EX                                              !0
         43        FETCH_CONSTANT                                   ~20     'CURLOPT_HTTPHEADER'
         44        SEND_VAL_EX                                              ~20
         45        SEND_VAL_EX                                              <array>
         46        DO_FCALL                                      0          
   25    47        INIT_FCALL_BY_NAME                                       'curl_exec'
         48        SEND_VAR_EX                                              !0
         49        DO_FCALL                                      0  $22     
         50        ASSIGN                                                   !3, $22
         51      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.81 ms | 1399 KiB | 13 Q