3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php /* Plugin Name: Ninja Forms - Change From Email Address */ add_action( 'ninja_forms_email_admin', 'ninja_forms_change_from_address' ); function ninja_forms_change_from_address(){ global $ninja_forms_processing; if( 1 == $ninja_forms_processing->get_form_ID( ) ) { $user_email = $ninja_forms_processing->get_field_value( 24 ); $user_name = $ninja_forms_processing->get_field_value( 1 ); $user_email = $user_name." <".$user_email.">"; $ninja_forms_processing->update_form_setting( 'email_from', $user_email ); } } add_action( 'ninja_forms_name_admin', 'ninja_forms_change_from_name' ); function ninja_forms_change_from_name(){ global $ninja_forms_processing; if( 2 == $ninja_forms_processing->get_form_ID( ) ) { $user_email = $ninja_forms_processing->get_field_value( 10 ); $user_name = $ninja_forms_processing->get_field_value( 2 ); $user_email = $user_name." <".$user_email.">"; $ninja_forms_processing->update_form_setting( 'email_from', $user_email ); } }
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = -2
filename:       /in/hD75S
function name:  (null)
number of ops:  11
compiled vars:  none
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   6     0  E >   INIT_FCALL_BY_NAME                                       'add_action'
         1        SEND_VAL_EX                                              'ninja_forms_email_admin'
         2        SEND_VAL_EX                                              'ninja_forms_change_from_address'
         3        DO_FCALL                                      0          
   7     4        NOP                                                      
  17     5        INIT_FCALL_BY_NAME                                       'add_action'
         6        SEND_VAL_EX                                              'ninja_forms_name_admin'
         7        SEND_VAL_EX                                              'ninja_forms_change_from_name'
         8        DO_FCALL                                      0          
  18     9        NOP                                                      
  26    10      > RETURN                                                   1

Function ninja_forms_change_from_address:
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = 5, Position 2 = 21
Branch analysis from position: 5
Jump found. Position 1 = -2
Branch analysis from position: 21
filename:       /in/hD75S
function name:  ninja_forms_change_from_address
number of ops:  22
compiled vars:  !0 = $ninja_forms_processing, !1 = $user_email, !2 = $user_name
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   8     0  E >   BIND_GLOBAL                                              !0, 'ninja_forms_processing'
   9     1        INIT_METHOD_CALL                                         !0, 'get_form_ID'
         2        DO_FCALL                                      0  $3      
         3        IS_EQUAL                                         ~4      1, $3
         4      > JMPZ                                                     ~4, ->21
  10     5    >   INIT_METHOD_CALL                                         !0, 'get_field_value'
         6        SEND_VAL_EX                                              24
         7        DO_FCALL                                      0  $5      
         8        ASSIGN                                                   !1, $5
  11     9        INIT_METHOD_CALL                                         !0, 'get_field_value'
        10        SEND_VAL_EX                                              1
        11        DO_FCALL                                      0  $7      
        12        ASSIGN                                                   !2, $7
  12    13        CONCAT                                           ~9      !2, '+%3C'
        14        CONCAT                                           ~10     ~9, !1
        15        CONCAT                                           ~11     ~10, '%3E'
        16        ASSIGN                                                   !1, ~11
  13    17        INIT_METHOD_CALL                                         !0, 'update_form_setting'
        18        SEND_VAL_EX                                              'email_from'
        19        SEND_VAR_EX                                              !1
        20        DO_FCALL                                      0          
  15    21    > > RETURN                                                   null

End of function ninja_forms_change_from_address

Function ninja_forms_change_from_name:
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = 5, Position 2 = 21
Branch analysis from position: 5
Jump found. Position 1 = -2
Branch analysis from position: 21
filename:       /in/hD75S
function name:  ninja_forms_change_from_name
number of ops:  22
compiled vars:  !0 = $ninja_forms_processing, !1 = $user_email, !2 = $user_name
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  19     0  E >   BIND_GLOBAL                                              !0, 'ninja_forms_processing'
  20     1        INIT_METHOD_CALL                                         !0, 'get_form_ID'
         2        DO_FCALL                                      0  $3      
         3        IS_EQUAL                                         ~4      2, $3
         4      > JMPZ                                                     ~4, ->21
  21     5    >   INIT_METHOD_CALL                                         !0, 'get_field_value'
         6        SEND_VAL_EX                                              10
         7        DO_FCALL                                      0  $5      
         8        ASSIGN                                                   !1, $5
  22     9        INIT_METHOD_CALL                                         !0, 'get_field_value'
        10        SEND_VAL_EX                                              2
        11        DO_FCALL                                      0  $7      
        12        ASSIGN                                                   !2, $7
  23    13        CONCAT                                           ~9      !2, '+%3C'
        14        CONCAT                                           ~10     ~9, !1
        15        CONCAT                                           ~11     ~10, '%3E'
        16        ASSIGN                                                   !1, ~11
  24    17        INIT_METHOD_CALL                                         !0, 'update_form_setting'
        18        SEND_VAL_EX                                              'email_from'
        19        SEND_VAR_EX                                              !1
        20        DO_FCALL                                      0          
  26    21    > > RETURN                                                   null

End of function ninja_forms_change_from_name

Generated using Vulcan Logic Dumper, using php 7.3.0