3v4l.org

run code in 300+ PHP versions simultaneously
<?php $xml_object['executeCustomReportResponse']['reportDetail']['header']['columnName'] = array("Apple","Banana", "Carrot"); $xml_object['executeCustomReportResponse']['reportDetail']['header']['columnName']['RandomFlag'] =True; echo("\nData Type: ".gettype ( $xml_object )); echo("\n"); foreach($xml_object['executeCustomReportResponse']['reportDetail']['header']['columnName'] as $value){ echo($value." "); } $get_column_name = $xml_object['executeCustomReportResponse']['reportDetail']['header']['columnName']; echo("\nData Type of copy ".gettype( $get_column_name )); echo("\n"); foreach($get_column_name as $value){ echo($value." "); } echo("\n"."************"."\n"); function getGroupNames($xml_response){ global $ajax_data; $index_of_title_column; $index_of_group_type_column; $columns_array = (array)$xml_response->executeCustomReportResponse->reportDetail->header->columnName; $index_of_title_column = array_search("Apple", $columns_array); $index_of_group_type_column = array_search("Carrot", $columns_array); echo($index_of_title_column."\n"); echo($index_of_group_type_column."\n"); } getGroupNames($xml_object) ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 20, Position 2 = 24
Branch analysis from position: 20
2 jumps found. (Code = 78) Position 1 = 21, Position 2 = 24
Branch analysis from position: 21
1 jumps found. (Code = 42) Position 1 = 20
Branch analysis from position: 20
Branch analysis from position: 24
2 jumps found. (Code = 77) Position 1 = 35, Position 2 = 39
Branch analysis from position: 35
2 jumps found. (Code = 78) Position 1 = 36, Position 2 = 39
Branch analysis from position: 36
1 jumps found. (Code = 42) Position 1 = 35
Branch analysis from position: 35
Branch analysis from position: 39
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 39
Branch analysis from position: 24
filename:       /in/GAmHK
function name:  (null)
number of ops:  45
compiled vars:  !0 = $xml_object, !1 = $value, !2 = $get_column_name
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   FETCH_DIM_W                                      $3      !0, 'executeCustomReportResponse'
          1        FETCH_DIM_W                                      $4      $3, 'reportDetail'
          2        FETCH_DIM_W                                      $5      $4, 'header'
          3        ASSIGN_DIM                                               $5, 'columnName'
          4        OP_DATA                                                  <array>
    3     5        FETCH_DIM_W                                      $7      !0, 'executeCustomReportResponse'
          6        FETCH_DIM_W                                      $8      $7, 'reportDetail'
          7        FETCH_DIM_W                                      $9      $8, 'header'
          8        FETCH_DIM_W                                      $10     $9, 'columnName'
          9        ASSIGN_DIM                                               $10, 'RandomFlag'
         10        OP_DATA                                                  <true>
    4    11        GET_TYPE                                         ~12     !0
         12        CONCAT                                           ~13     '%0AData+Type%3A+', ~12
         13        ECHO                                                     ~13
    5    14        ECHO                                                     '%0A'
    7    15        FETCH_DIM_R                                      ~14     !0, 'executeCustomReportResponse'
         16        FETCH_DIM_R                                      ~15     ~14, 'reportDetail'
         17        FETCH_DIM_R                                      ~16     ~15, 'header'
         18        FETCH_DIM_R                                      ~17     ~16, 'columnName'
         19      > FE_RESET_R                                       $18     ~17, ->24
         20    > > FE_FETCH_R                                               $18, !1, ->24
    8    21    >   CONCAT                                           ~19     !1, '+'
         22        ECHO                                                     ~19
    7    23      > JMP                                                      ->20
         24    >   FE_FREE                                                  $18
   11    25        FETCH_DIM_R                                      ~20     !0, 'executeCustomReportResponse'
         26        FETCH_DIM_R                                      ~21     ~20, 'reportDetail'
         27        FETCH_DIM_R                                      ~22     ~21, 'header'
         28        FETCH_DIM_R                                      ~23     ~22, 'columnName'
         29        ASSIGN                                                   !2, ~23
   12    30        GET_TYPE                                         ~25     !2
         31        CONCAT                                           ~26     '%0AData+Type+of+copy+', ~25
         32        ECHO                                                     ~26
   13    33        ECHO                                                     '%0A'
   14    34      > FE_RESET_R                                       $27     !2, ->39
         35    > > FE_FETCH_R                                               $27, !1, ->39
   15    36    >   CONCAT                                           ~28     !1, '+'
         37        ECHO                                                     ~28
   14    38      > JMP                                                      ->35
         39    >   FE_FREE                                                  $27
   17    40        ECHO                                                     '%0A%2A%2A%2A%2A%2A%2A%2A%2A%2A%2A%2A%2A%0A'
   30    41        INIT_FCALL                                               'getgroupnames'
         42        SEND_VAR                                                 !0
         43        DO_FCALL                                      0          
   31    44      > RETURN                                                   1

Function getgroupnames:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/GAmHK
function name:  getGroupNames
number of ops:  23
compiled vars:  !0 = $xml_response, !1 = $ajax_data, !2 = $index_of_title_column, !3 = $index_of_group_type_column, !4 = $columns_array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   19     0  E >   RECV                                             !0      
   20     1        BIND_GLOBAL                                              !1, 'ajax_data'
   23     2        FETCH_OBJ_R                                      ~5      !0, 'executeCustomReportResponse'
          3        FETCH_OBJ_R                                      ~6      ~5, 'reportDetail'
          4        FETCH_OBJ_R                                      ~7      ~6, 'header'
          5        FETCH_OBJ_R                                      ~8      ~7, 'columnName'
          6        CAST                                          7  ~9      ~8
          7        ASSIGN                                                   !4, ~9
   24     8        INIT_FCALL                                               'array_search'
          9        SEND_VAL                                                 'Apple'
         10        SEND_VAR                                                 !4
         11        DO_ICALL                                         $11     
         12        ASSIGN                                                   !2, $11
   25    13        INIT_FCALL                                               'array_search'
         14        SEND_VAL                                                 'Carrot'
         15        SEND_VAR                                                 !4
         16        DO_ICALL                                         $13     
         17        ASSIGN                                                   !3, $13
   26    18        CONCAT                                           ~15     !2, '%0A'
         19        ECHO                                                     ~15
   27    20        CONCAT                                           ~16     !3, '%0A'
         21        ECHO                                                     ~16
   28    22      > RETURN                                                   null

End of function getgroupnames

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
181.18 ms | 1403 KiB | 16 Q