gform_field_content

The Gravity Forms Directory & Addons gform field content hook.

Description

apply_filters( 'gform_field_content', (unknown) $content, (unknown) $field, (unknown) $value, (unknown) $lead_id, (unknown) $form_id ); 

Parameters (5)

0. $content (unknown)
The content.
1. $field (unknown)
The field.
2. $value (unknown)
The value.
3. $lead_id (unknown)
The lead id.
4. $form_id (unknown)
The form id.

Usage

To run the hook, copy the example below.
  1. $content = apply_filters( 'gform_field_content', $content, $field, $value, $lead_id, $form_id ); 
  2.  
  3. if ( !empty( $content ) ) { 
  4.  
  5. // everything has led up to this point... 
  6.  
  7.  
The following example is for adding a hook callback.
  1. // define the gform_field_content callback 
  2. function filter_gform_field_content( $content, $field, $value, $lead_id, $form_id ) { 
  3. // make filter magic happen here... 
  4. return $content
  5. }; 
  6.  
  7. // add the filter 
  8. add_filter( 'gform_field_content', 'filter_gform_field_content', 10, 5 ); 
To remove a hook callback, use the example below.
  1. // remove the filter 
  2. remove_filter( 'gform_field_content', 'filter_gform_field_content', 10, 5 ); 

Defined (1)

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

/gravity-forms-addons.php  
  1. $content = apply_filters( "gform_field_content", $content, $field, $value, $lead["id"], $Form["id"] );