nf_deprecate_form_import

The Ninja Forms nf deprecate form import function.

Description

nf_deprecate_form_import( $form ); 

Parameters (1)

0. $form
The form.

Usage

  1. if ( !function_exists( 'nf_deprecate_form_import' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'ninja-forms/deprecated/includes/deprecated.php'; 
  3.  
  4. // The form. 
  5. $form = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = nf_deprecate_form_import($form); 
  9.  

Defined (1)

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

/deprecated/includes/deprecated.php  
  1. function nf_deprecate_form_import( $form ) { 
  2. if ( isset ( $form['data']['admin_mailto'] ) ) 
  3. unset( $form['data']['admin_mailto'] ); 
  4.  
  5. if ( isset ( $form['data']['admin_email'] ) ) 
  6. unset( $form['data']['admin_email'] ); 
  7.  
  8. if ( isset ( $form['data']['admin_subject'] ) ) 
  9. unset( $form['data']['admin_subject'] ); 
  10.  
  11. if ( isset ( $form['data']['user_mailto'] ) ) 
  12. unset( $form['data']['user_mailto'] ); 
  13.  
  14. if ( isset ( $form['data']['user_email'] ) ) 
  15. unset( $form['data']['user_email'] ); 
  16.  
  17. if ( isset ( $form['data']['user_subject'] ) ) 
  18. unset ( $form['data']['user_subject'] ); 
  19.  
  20. if ( isset ( $form['data']['landing_page'] ) ) 
  21. unset ( $form['data']['landing_page'] ); 
  22.  
  23. return $form;