nf_remove_old_email_settings

Remove old email "send to" settings from form fiels.

Description

nf_remove_old_email_settings( (string) $form_id = '' ); 

Parameters (1)

0. $form_id — Optional. (string) => ''
The form id.

Usage

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

Defined (1)

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

/deprecated/includes/admin/upgrades/upgrade-functions.php  
  1. function nf_remove_old_email_settings( $form_id = '' ) { 
  2.  
  3. if ( '' == $form_id ) { 
  4. $forms = ninja_forms_get_all_forms( true ); 
  5.  
  6. if ( is_array( $forms ) ) { 
  7. foreach ( $forms as $form ) { 
  8. nf_remove_old_email_send_to( $form['id'] ); 
  9. } else {