3v4l.org

run code in 300+ PHP versions simultaneously
<?php function compose_mail($post) { $ignore_fields = array('G-recaptcha-response'); $content = "Form submission: \n\n"; foreach($post as $name=>$value) { if(!in_array($name,$ignore_fields)) { $content .= ucwords($name).":\n"; $content .= "$value\n\n"; } } return $content; } $array = array( 'lala' => 'tralala', 'waai' => 'woei', 'G-recaptcha-response'=> 'nee' ); echo compose_mail($array);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/DPjkN
function name:  (null)
number of ops:  6
compiled vars:  !0 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   16     0  E >   ASSIGN                                                   !0, <array>
   22     1        INIT_FCALL                                               'compose_mail'
          2        SEND_VAR                                                 !0
          3        DO_FCALL                                      0  $2      
          4        ECHO                                                     $2
          5      > RETURN                                                   1

Function compose_mail:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 4, Position 2 = 21
Branch analysis from position: 4
2 jumps found. (Code = 78) Position 1 = 5, Position 2 = 21
Branch analysis from position: 5
2 jumps found. (Code = 43) Position 1 = 12, Position 2 = 20
Branch analysis from position: 12
1 jumps found. (Code = 42) Position 1 = 4
Branch analysis from position: 4
Branch analysis from position: 20
Branch analysis from position: 21
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 21
filename:       /in/DPjkN
function name:  compose_mail
number of ops:  24
compiled vars:  !0 = $post, !1 = $ignore_fields, !2 = $content, !3 = $value, !4 = $name
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    4     1        ASSIGN                                                   !1, <array>
    5     2        ASSIGN                                                   !2, 'Form+submission%3A+%0A%0A'
    6     3      > FE_RESET_R                                       $7      !0, ->21
          4    > > FE_FETCH_R                                       ~8      $7, !3, ->21
          5    >   ASSIGN                                                   !4, ~8
    7     6        INIT_FCALL                                               'in_array'
          7        SEND_VAR                                                 !4
          8        SEND_VAR                                                 !1
          9        DO_ICALL                                         $10     
         10        BOOL_NOT                                         ~11     $10
         11      > JMPZ                                                     ~11, ->20
    8    12    >   INIT_FCALL                                               'ucwords'
         13        SEND_VAR                                                 !4
         14        DO_ICALL                                         $12     
         15        CONCAT                                           ~13     $12, '%3A%0A'
         16        ASSIGN_OP                                     8          !2, ~13
    9    17        NOP                                                      
         18        FAST_CONCAT                                      ~15     !3, '%0A%0A'
         19        ASSIGN_OP                                     8          !2, ~15
    6    20    > > JMP                                                      ->4
         21    >   FE_FREE                                                  $7
   13    22      > RETURN                                                   !2
   14    23*     > RETURN                                                   null

End of function compose_mail

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
174.49 ms | 1399 KiB | 18 Q