ninja_forms_field_country_type_filter

Function that filters the hidden field output by display that identifies the field type.

Description

ninja_forms_field_country_type_filter( $field_type, $field_id ); 

This is a work around and will need to be removed once proper field registration is in place.

Parameters (2)

0. $field_type
The field type.
1. $field_id
The field id.

Usage

  1. if ( !function_exists( 'ninja_forms_field_country_type_filter' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'ninja-forms/deprecated/includes/fields/country.php'; 
  3.  
  4. // The field type. 
  5. $field_type = null; 
  6.  
  7. // The field id. 
  8. $field_id = null; 
  9.  
  10. // NOTICE! Understand what this does before running. 
  11. $result = ninja_forms_field_country_type_filter($field_type, $field_id); 
  12.  

Defined (1)

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

/deprecated/includes/fields/country.php  
  1. function ninja_forms_field_country_type_filter( $field_type, $field_id ) { 
  2. $field = ninja_forms_get_field_by_id( $field_id ); 
  3. if ( $field['type'] == '_country' ) { 
  4. $field_type = 'list'; 
  5.  
  6. return $field_type;