gform_date_min_year

The Gravity Forms gform date min year hook.

Description

apply_filters( 'gform_date_min_year', (string) 20, (unknown) $form, (unknown) $instance ); 

Parameters (3)

0. $1920 (string) => '1920'
The 1920.
1. $form (unknown)
The form.
2. $instance (unknown)
The this.

Usage

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

Defined (2)

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

/includes/fields/class-gf-field-date.php  
  1. $year_min = apply_filters( 'gform_date_min_year', '1920', $form, $this ); 
  1. $year_min = apply_filters( 'gform_date_min_year', '1920', $form, $this );