nf_edit_sub_date_modified
The Ninja Forms nf edit sub date modified hook.
Description
apply_filters( 'nf_edit_sub_date_modified', (unknown) $sub_get_mod_date_m_d_y_h_i, (unknown) $post_id );
Parameters (2)
- 0. $sub_get_mod_date_m_d_y_h_i (unknown)
- The sub get mod date m d y h i.
- 1. $post_id (unknown)
- The post id.
Usage
- To run the hook, copy the example below.
- $sub_get_mod_date_m_d_y_h_i = apply_filters( 'nf_edit_sub_date_modified', $sub_get_mod_date_m_d_y_h_i, $post_id );
- if ( !empty( $sub_get_mod_date_m_d_y_h_i ) ) {
- // everything has led up to this point...
- }
- The following example is for adding a hook callback.
- // define the nf_edit_sub_date_modified callback
- function filter_nf_edit_sub_date_modified( $sub_get_mod_date_m_d_y_h_i, $post_id ) {
- // make filter magic happen here...
- return $sub_get_mod_date_m_d_y_h_i;
- };
- // add the filter
- add_filter( 'nf_edit_sub_date_modified', 'filter_nf_edit_sub_date_modified', 10, 2 );
- To remove a hook callback, use the example below.
- // remove the filter
- remove_filter( 'nf_edit_sub_date_modified', 'filter_nf_edit_sub_date_modified', 10, 2 );
Defined (2)
The filter is defined in the following location(s).
- /includes/Admin/CPT/Submission.php
- $mod_date = apply_filters( 'nf_edit_sub_date_modified', $sub->get_mod_date( 'm/d/Y H:i' ), $post->ID );
- /deprecated/classes/subs-cpt.php
- $date_modified = apply_filters( 'nf_edit_sub_date_modified', date( 'M j, Y @ h:i', strtotime( $post->post_modified ) ), $post->ID );