Easy Forms for MailChimp - Version 6.0.4

Version Description

Download this release

Release Info

Developer eherman24
Plugin Icon 128x128 Easy Forms for MailChimp
Version 6.0.4
Comparing to
See all releases

Code changes from version 6.0.3.9 to 6.0.4

admin/class-yikes-inc-easy-mailchimp-extender-admin.php CHANGED
@@ -178,6 +178,9 @@ class Yikes_Inc_Easy_Mailchimp_Forms_Admin {
178
  add_action( 'admin_print_scripts', array( $this, 'alter_yikes_easy_mc_color_scheme' ) );
179
  // hook in and display our knowledge base articles on the support page
180
  add_action( 'yikes-mailchimp-support-page', array( $this, 'hook_and_display_kb_article_RSS' ) );
 
 
 
181
  }
182
 
183
  /*
@@ -2862,6 +2865,20 @@ class Yikes_Inc_Easy_Mailchimp_Forms_Admin {
2862
  include_once( YIKES_MC_PATH . 'admin/partials/helpers/knowledge-base-articles-RSS.php' );
2863
  }
2864
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2865
  /*
2866
  * Process [yikes-mailchimp-form-description] into the shortcode
2867
  * @since 6.0.4.4
178
  add_action( 'admin_print_scripts', array( $this, 'alter_yikes_easy_mc_color_scheme' ) );
179
  // hook in and display our knowledge base articles on the support page
180
  add_action( 'yikes-mailchimp-support-page', array( $this, 'hook_and_display_kb_article_RSS' ) );
181
+ // ensure that the upgrade went smoothly, else we have to let the user know we need to upgrade the database
182
+ // after upgrading f rom 6.0.3.7 users need to upgrade the database as well
183
+ add_action( 'plugins_loaded', array( $this, 'check_yikes_mc_table_version' ) );
184
  }
185
 
186
  /*
2865
  include_once( YIKES_MC_PATH . 'admin/partials/helpers/knowledge-base-articles-RSS.php' );
2866
  }
2867
 
2868
+ /**
2869
+ * Check the users version number, and display a notice to upgrade the databse if needed
2870
+ * @since 6.0.4
2871
+ */
2872
+ public function check_yikes_mc_table_version() {
2873
+ if( get_option( 'yikes_mc_database_version', '0.00' ) < '1.0' ) {
2874
+ require_once YIKES_MC_PATH . 'includes/class-yikes-inc-easy-mailchimp-extender-activator.php';
2875
+ global $wpdb;
2876
+ Yikes_Inc_Easy_Mailchimp_Extender_Activator::_activate_yikes_easy_mailchimp( $wpdb );
2877
+ // update the database option
2878
+ update_option( 'yikes_mc_database_version', '1.0' );
2879
+ }
2880
+ }
2881
+
2882
  /*
2883
  * Process [yikes-mailchimp-form-description] into the shortcode
2884
  * @since 6.0.4.4
includes/class-yikes-inc-easy-mailchimp-extender-activator.php CHANGED
@@ -70,27 +70,27 @@ class Yikes_Inc_Easy_Mailchimp_Extender_Activator {
70
  $charset_collate = $wpdb->get_charset_collate();
71
 
72
  // create the Yikes Inc. Easy MailChimp database table
73
- $sql = "CREATE TABLE " . $custom_table_name . " (
74
- `id` mediumint(9) NOT NULL AUTO_INCREMENT,
75
- `list_id` TINYTEXT NOT NULL,
76
- `form_name` MEDIUMTEXT NOT NULL,
77
- `form_description` LONGTEXT NOT NULL,
78
- `fields` LONGTEXT NOT NULL,
79
- `custom_styles` MEDIUMTEXT NOT NULL,
80
- `custom_template` TINYTEXT NOT NULL,
81
- `send_welcome_email` INT(1) NOT NULL,
82
- `redirect_user_on_submit` INT(1) NOT NULL,
83
- `redirect_page` MEDIUMTEXT NOT NULL,
84
- `submission_settings` LONGTEXT NOT NULL,
85
- `optin_settings` LONGTEXT NOT NULL,
86
- `form_settings` LONGTEXT NOT NULL,
87
- `error_messages` LONGTEXT NOT NULL,
88
- `custom_notifications` LONGTEXT NOT NULL,
89
- `impressions` INT NOT NULL,
90
- `submissions` INT NOT NULL,
91
- `custom_fields` LONGTEXT NOT NULL,
92
  UNIQUE KEY id (id)
93
- ) " . $charset_collate . ";";
94
  require_once(ABSPATH . 'wp-admin/includes/upgrade.php');
95
  dbDelta($sql);
96
 
70
  $charset_collate = $wpdb->get_charset_collate();
71
 
72
  // create the Yikes Inc. Easy MailChimp database table
73
+ $sql = "CREATE TABLE $custom_table_name (
74
+ id mediumint(9) NOT NULL AUTO_INCREMENT,
75
+ list_id TINYTEXT NOT NULL,
76
+ form_name MEDIUMTEXT NOT NULL,
77
+ form_description LONGTEXT NOT NULL,
78
+ fields LONGTEXT NOT NULL,
79
+ custom_styles MEDIUMTEXT NOT NULL,
80
+ custom_template TINYTEXT NOT NULL,
81
+ send_welcome_email INT(1) NOT NULL,
82
+ redirect_user_on_submit INT(1) NOT NULL,
83
+ redirect_page MEDIUMTEXT NOT NULL,
84
+ submission_settings LONGTEXT NOT NULL,
85
+ optin_settings LONGTEXT NOT NULL,
86
+ form_settings LONGTEXT NOT NULL,
87
+ error_messages LONGTEXT NOT NULL,
88
+ custom_notifications LONGTEXT NOT NULL,
89
+ impressions INT NOT NULL,
90
+ submissions INT NOT NULL,
91
+ custom_fields LONGTEXT NOT NULL,
92
  UNIQUE KEY id (id)
93
+ ) $charset_collate;";
94
  require_once(ABSPATH . 'wp-admin/includes/upgrade.php');
95
  dbDelta($sql);
96
 
includes/class-yikes-inc-easy-mailchimp-extender-uninstall.php CHANGED
@@ -71,6 +71,7 @@ class Yikes_Inc_Easy_Mailchimp_Extender_Uninstaller {
71
  delete_option( 'yikes-mc-recaptcha-site-key' );
72
  delete_option( 'yikes-mc-recaptcha-secret-key' );
73
  delete_option( 'yikes-mc-error-messages' );
 
74
  delete_option( 'yikes_mailchimp_activation_redirect' ); /* delete the activation re-direct */
75
  }
76
 
71
  delete_option( 'yikes-mc-recaptcha-site-key' );
72
  delete_option( 'yikes-mc-recaptcha-secret-key' );
73
  delete_option( 'yikes-mc-error-messages' );
74
+ delete_option( 'yikes_mc_database_version' ); // delete the database verison
75
  delete_option( 'yikes_mailchimp_activation_redirect' ); /* delete the activation re-direct */
76
  }
77
 
includes/class-yikes-inc-easy-mailchimp-extender.php CHANGED
@@ -62,7 +62,7 @@ class Yikes_Inc_Easy_Mailchimp_Extender {
62
  */
63
  public function __construct() {
64
  $this->yikes_inc_easy_mailchimp_extender = 'yikes-inc-easy-mailchimp-extender';
65
- $this->version = '6.0.3.9';
66
  $this->load_dependencies();
67
  $this->set_locale();
68
  $this->define_admin_hooks();
62
  */
63
  public function __construct() {
64
  $this->yikes_inc_easy_mailchimp_extender = 'yikes-inc-easy-mailchimp-extender';
65
+ $this->version = '6.0.4';
66
  $this->load_dependencies();
67
  $this->set_locale();
68
  $this->define_admin_hooks();
readme.txt CHANGED
@@ -1 +1 @@
1
- === Easy Forms for MailChimp ===
2
- added `stripslashes()` to the following settings fields :
3
- Updated readme FAQ section
4
- added `stripslashes()` to the following settings fields :
5
- Updated readme FAQ section
6
- added `stripslashes()` to the following settings fields :
7
- Updated readme FAQ section
8
- added `stripslashes()` to the following settings fields :
9
- Updated readme FAQ section
1
+ === Easy Forms for MailChimp ===
 
 
 
 
 
 
 
 
yikes-inc-easy-mailchimp-extender.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: Easy Forms for MailChimp by YIKES
4
  * Plugin URI: http://www.yikesinc.com/services/yikes-inc-easy-mailchimp-extender/
5
  * Description: YIKES Easy Forms for MailChimp links your site to MailChimp and allows you to generate and display mailing list opt-in forms anywhere on your site with ease.
6
- * Version: 6.0.3.9
7
  * Author: YIKES
8
  * Author URI: http://www.yikesinc.com/
9
  * License: GPL-3.0+
3
  * Plugin Name: Easy Forms for MailChimp by YIKES
4
  * Plugin URI: http://www.yikesinc.com/services/yikes-inc-easy-mailchimp-extender/
5
  * Description: YIKES Easy Forms for MailChimp links your site to MailChimp and allows you to generate and display mailing list opt-in forms anywhere on your site with ease.
6
+ * Version: 6.0.4
7
  * Author: YIKES
8
  * Author URI: http://www.yikesinc.com/
9
  * License: GPL-3.0+