ninja_forms_sidebar_payment_fields

The Ninja Forms ninja forms sidebar payment fields function.

Description

ninja_forms_sidebar_payment_fields(); 

Usage

  1. if ( !function_exists( 'ninja_forms_sidebar_payment_fields' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'ninja-forms/deprecated/includes/admin/pages/ninja-forms/tabs/field-settings/sidebars/payment-fields.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = ninja_forms_sidebar_payment_fields(); 
  7.  

Defined (1)

The function is defined in the following location(s).

/deprecated/includes/admin/pages/ninja-forms/tabs/field-settings/sidebars/payment-fields.php  
  1. function ninja_forms_sidebar_payment_fields() { 
  2. global $wpdb, $ninja_forms_fields; 
  3. $field_results = ninja_forms_get_all_defs(); 
  4.  
  5. if(is_array($field_results)) { 
  6. foreach($field_results as $field) { 
  7. $data = $field['data']; 
  8. if ( isset ( $data['payment_field_group'] ) AND $data['payment_field_group'] == 1 ) { 
  9. $name = $field['name']; 
  10. $field_id = $field['id']; 
  11. $type = $field['type']; 
  12. if ( isset ( $ninja_forms_fields[$type] ) ) { 
  13. $reg_field = $ninja_forms_fields[$type]; 
  14.  
  15. $limit = ''; 
  16.  
  17. ?> 
  18. <p class="button-controls" id="ninja_forms_insert_def_field_<?php echo $field_id;?>_p"> 
  19. <a class="button-secondary ninja-forms-insert-def-field" id="ninja_forms_insert_def_field_<?php echo $field_id;?>" data-limit="<?php echo $limit; ?>" data-field="<?php echo $field_id; ?>" data-type="<?php echo $type; ?>" href="#" rel="<?php echo $type;?>"><?php _e( $name, 'ninja-forms' ); ?></a> 
  20. </p> 
  21. <?php 
  22. }  
  23.  
  24.