Ninja Forms – The Easy and Powerful Forms Builder - Version 3.3.12

Version Description

(31 July 2018) =

Bugs:

  • Resolved an issue that sometimes caused form titles to not display in dropdown menus.

=

Download this release

Release Info

Developer ericwindhamsd
Plugin Icon 128x128 Ninja Forms – The Easy and Powerful Forms Builder
Version 3.3.12
Comparing to
See all releases

Code changes from version 3.3.11 to 3.3.12

Files changed (3) hide show
  1. deprecated/ninja-forms.php +1 -1
  2. ninja-forms.php +26 -4
  3. readme.txt +10 -4
deprecated/ninja-forms.php CHANGED
@@ -265,7 +265,7 @@ class Ninja_Forms {
265
 
266
  // Plugin version
267
  if ( ! defined( 'NF_PLUGIN_VERSION' ) )
268
- define( 'NF_PLUGIN_VERSION', '3.3.11' );
269
 
270
  // Plugin Folder Path
271
  if ( ! defined( 'NF_PLUGIN_DIR' ) )
265
 
266
  // Plugin version
267
  if ( ! defined( 'NF_PLUGIN_VERSION' ) )
268
+ define( 'NF_PLUGIN_VERSION', '3.3.12' );
269
 
270
  // Plugin Folder Path
271
  if ( ! defined( 'NF_PLUGIN_DIR' ) )
ninja-forms.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Ninja Forms
4
  Plugin URI: http://ninjaforms.com/
5
  Description: Ninja Forms is a webform builder with unparalleled ease of use and features.
6
- Version: 3.3.11
7
  Author: The WP Ninjas
8
  Author URI: http://ninjaforms.com
9
  Text Domain: ninja-forms
@@ -58,7 +58,7 @@ if( get_option( 'ninja_forms_load_deprecated', FALSE ) && ! ( isset( $_POST[ 'nf
58
  /**
59
  * @since 3.0
60
  */
61
- const VERSION = '3.3.11';
62
 
63
  const WP_MIN_VERSION = '4.7';
64
 
@@ -226,8 +226,16 @@ if( get_option( 'ninja_forms_load_deprecated', FALSE ) && ! ( isset( $_POST[ 'nf
226
  update_option( 'ninja_forms_version', self::VERSION );
227
  // If we've not recorded our db version...
228
  if ( ! get_option( 'ninja_forms_db_version' ) ) {
229
- // Set it to the baseline (1.0).
230
- add_option( 'ninja_forms_db_version', '1.1', '', 'no' );
 
 
 
 
 
 
 
 
231
  }
232
 
233
  /*
@@ -407,6 +415,20 @@ if( get_option( 'ninja_forms_load_deprecated', FALSE ) && ! ( isset( $_POST[ 'nf
407
  // Update our db version.
408
  update_option( 'ninja_forms_db_version', '1.1' );
409
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
410
  }
411
  }
412
 
3
  Plugin Name: Ninja Forms
4
  Plugin URI: http://ninjaforms.com/
5
  Description: Ninja Forms is a webform builder with unparalleled ease of use and features.
6
+ Version: 3.3.12
7
  Author: The WP Ninjas
8
  Author URI: http://ninjaforms.com
9
  Text Domain: ninja-forms
58
  /**
59
  * @since 3.0
60
  */
61
+ const VERSION = '3.3.12';
62
 
63
  const WP_MIN_VERSION = '4.7';
64
 
226
  update_option( 'ninja_forms_version', self::VERSION );
227
  // If we've not recorded our db version...
228
  if ( ! get_option( 'ninja_forms_db_version' ) ) {
229
+ // If this isn't a fresh install...
230
+ // AND If we're upgrading from a version before 3.3.0...
231
+ if ( $saved_version && version_compare( $saved_version, '3.3.0', '<' ) ) {
232
+ // Set it to the baseline (1.0) so that our upgrade process will run properly.
233
+ add_option( 'ninja_forms_db_version', '1.0', '', 'no' );
234
+ }
235
+ else {
236
+ // Set it to 1.1.
237
+ add_option( 'ninja_forms_db_version', '1.1', '', 'no' );
238
+ }
239
  }
240
 
241
  /*
415
  // Update our db version.
416
  update_option( 'ninja_forms_db_version', '1.1' );
417
  }
418
+ // Fix for legacy versions that upgraded without a set DB version.
419
+ // If our version is exactly 1.1...
420
+ if ( version_compare( get_option( 'ninja_forms_db_version' ), '1.1', '==' ) ) {
421
+ global $wpdb;
422
+ // Fetch the form_title column from the fields table.
423
+ $sql = "SHOW FULL COLUMNS FROM `{$wpdb->prefix}nf3_forms` WHERE Field = 'form_title'";
424
+ $result = $wpdb->get_results( $sql, 'ARRAY_A' );
425
+ // If we didn't get a result...
426
+ if ( empty( $result ) ) {
427
+ // Do our stage 1 updates, even though they should have already run.
428
+ $migrations->do_stage_one();
429
+ }
430
+ }
431
+
432
  }
433
  }
434
 
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: wpninjasllc, kstover, jameslaws, kbjohnson90, klhall1987, krmoorho
3
  Tags: form, forms, contact form, custom form, form builder, form creator, form manager, form creation, contact forms, custom forms, forms builder, forms creator, forms manager, forms creation, form administration,
4
  Requires at least: 4.7
5
  Tested up to: 4.9
6
- Stable tag: 3.3.11
7
  License: GPLv2 or later
8
 
9
  Drag and drop fields in an intuitive UI to create contact forms, email subscription forms, order forms, payment forms, send emails and more!
@@ -111,14 +111,20 @@ For help and video tutorials, please visit our website: [Ninja Forms Documentati
111
 
112
  == Upgrade Notice ==
113
 
114
- = 3.3.11 (23 July 2018) =
115
 
116
- *Changes:*
117
 
118
- * Updated save methods for form settings to reduce potential encoding errors.
119
 
120
  == Changelog ==
121
 
 
 
 
 
 
 
122
  = 3.3.11 (23 July 2018) =
123
 
124
  *Changes:*
3
  Tags: form, forms, contact form, custom form, form builder, form creator, form manager, form creation, contact forms, custom forms, forms builder, forms creator, forms manager, forms creation, form administration,
4
  Requires at least: 4.7
5
  Tested up to: 4.9
6
+ Stable tag: 3.3.12
7
  License: GPLv2 or later
8
 
9
  Drag and drop fields in an intuitive UI to create contact forms, email subscription forms, order forms, payment forms, send emails and more!
111
 
112
  == Upgrade Notice ==
113
 
114
+ = 3.3.12 (31 July 2018) =
115
 
116
+ *Bugs:*
117
 
118
+ * Resolved an issue that sometimes caused form titles to not display in dropdown menus.
119
 
120
  == Changelog ==
121
 
122
+ = 3.3.12 (31 July 2018) =
123
+
124
+ *Bugs:*
125
+
126
+ * Resolved an issue that sometimes caused form titles to not display in dropdown menus.
127
+
128
  = 3.3.11 (23 July 2018) =
129
 
130
  *Changes:*