Version Description
Download this release
Release Info
Developer | eherman24 |
Plugin | Easy Forms for MailChimp |
Version | 6.0.5.1 |
Comparing to | |
See all releases |
Code changes from version 6.0.5 to 6.0.5.1
- admin/class-yikes-inc-easy-mailchimp-extender-admin.php +4 -2
- admin/partials/edit-form.php +2 -2
- includes/class-yikes-inc-easy-mailchimp-extender.php +1 -1
- public/partials/shortcodes/process/process_form_submission.php +8 -0
- public/partials/shortcodes/process/process_form_submission_ajax.php +4 -0
- readme.txt +1 -9
- yikes-inc-easy-mailchimp-extender.php +1 -1
admin/class-yikes-inc-easy-mailchimp-extender-admin.php
CHANGED
@@ -1685,8 +1685,10 @@ class Yikes_Inc_Easy_Mailchimp_Forms_Admin {
|
|
1685 |
}
|
1686 |
|
1687 |
// loop over interest groups
|
1688 |
-
|
1689 |
-
$
|
|
|
|
|
1690 |
}
|
1691 |
|
1692 |
// build our assigned fields
|
1685 |
}
|
1686 |
|
1687 |
// loop over interest groups
|
1688 |
+
if( ! empty( $interest_groups ) && ! isset( $interest_groups['error'] ) ) {
|
1689 |
+
foreach( $interest_groups as $interest_group ) {
|
1690 |
+
$available_interest_groups[] = $interest_group['id'];
|
1691 |
+
}
|
1692 |
}
|
1693 |
|
1694 |
// build our assigned fields
|
admin/partials/edit-form.php
CHANGED
@@ -284,14 +284,14 @@
|
|
284 |
|
285 |
<div id="interest-groups-container" class="list-container">
|
286 |
<?php
|
287 |
-
if( isset( $interest_groupings ) &&
|
288 |
// build a list of available merge variables,
|
289 |
// but exclude the ones already assigned to the form
|
290 |
echo '<p class="description">' . __( "Select an interest group below to add to the form builder." , 'yikes-inc-easy-mailchimp-extender' ) . '</p>';
|
291 |
// $this->build_available_merge_vars( json_decode( $form['fields'] , true ) , $available_merge_variables );
|
292 |
$this->build_available_interest_groups( json_decode( $form['fields'] , true ) , $interest_groupings , $form['list_id'] );
|
293 |
} else {
|
294 |
-
echo $
|
295 |
}
|
296 |
?>
|
297 |
</div>
|
284 |
|
285 |
<div id="interest-groups-container" class="list-container">
|
286 |
<?php
|
287 |
+
if( isset( $interest_groupings ) && ! isset( $interest_groupings['error'] ) ) {
|
288 |
// build a list of available merge variables,
|
289 |
// but exclude the ones already assigned to the form
|
290 |
echo '<p class="description">' . __( "Select an interest group below to add to the form builder." , 'yikes-inc-easy-mailchimp-extender' ) . '</p>';
|
291 |
// $this->build_available_merge_vars( json_decode( $form['fields'] , true ) , $available_merge_variables );
|
292 |
$this->build_available_interest_groups( json_decode( $form['fields'] , true ) , $interest_groupings , $form['list_id'] );
|
293 |
} else {
|
294 |
+
echo '<p class="description">' . $interest_groupings['error'] . '</p>';
|
295 |
}
|
296 |
?>
|
297 |
</div>
|
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.5';
|
66 |
$this->load_dependencies();
|
67 |
$this->define_admin_hooks();
|
68 |
$this->define_public_hooks();
|
62 |
*/
|
63 |
public function __construct() {
|
64 |
$this->yikes_inc_easy_mailchimp_extender = 'yikes-inc-easy-mailchimp-extender';
|
65 |
+
$this->version = '6.0.5.1';
|
66 |
$this->load_dependencies();
|
67 |
$this->define_admin_hooks();
|
68 |
$this->define_public_hooks();
|
public/partials/shortcodes/process/process_form_submission.php
CHANGED
@@ -207,6 +207,14 @@ if ( ! isset( $_POST['yikes_easy_mc_new_subscriber'] ) || ! wp_verify_nonce( $_P
|
|
207 |
// generic error
|
208 |
$process_submission_response = '<p class="yikes-easy-mc-error-message">' . str_replace( ' and cannot be imported', '', str_replace( 'List_RoleEmailMember:', '', $subscribe_response['error'] ) ) . '</p>';
|
209 |
break;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
210 |
default:
|
211 |
// generic error
|
212 |
if( ! empty( $form_settings['error_messages']['general-error'] ) ) {
|
207 |
// generic error
|
208 |
$process_submission_response = '<p class="yikes-easy-mc-error-message">' . str_replace( ' and cannot be imported', '', str_replace( 'List_RoleEmailMember:', '', $subscribe_response['error'] ) ) . '</p>';
|
209 |
break;
|
210 |
+
// invalid email (or no email at all)
|
211 |
+
case '-100':
|
212 |
+
if( ! empty( $form_settings['error_messages']['invalid-email'] ) ) {
|
213 |
+
$process_submission_response = '<p class="yikes-easy-mc-error-message">' . $form_settings['error_messages']['invalid-email'] . '</p>';
|
214 |
+
} else {
|
215 |
+
$process_submission_response = '<p class="yikes-easy-mc-error-message">' . $subscribe_response['error'] . '</p>';
|
216 |
+
}
|
217 |
+
break;
|
218 |
default:
|
219 |
// generic error
|
220 |
if( ! empty( $form_settings['error_messages']['general-error'] ) ) {
|
public/partials/shortcodes/process/process_form_submission_ajax.php
CHANGED
@@ -203,6 +203,10 @@ if( isset( $merge_variables['error'] ) ) {
|
|
203 |
// generic error
|
204 |
$error_response = str_replace( ' and cannot be imported', '', str_replace( 'List_RoleEmailMember:', '', $subscribe_response['error'] ) );
|
205 |
break;
|
|
|
|
|
|
|
|
|
206 |
default:
|
207 |
$error_response = ( ! empty( $error_messages['general-error'] ) ) ? $error_messages['general-error'] : $subscribe_response['error'];
|
208 |
break;
|
203 |
// generic error
|
204 |
$error_response = str_replace( ' and cannot be imported', '', str_replace( 'List_RoleEmailMember:', '', $subscribe_response['error'] ) );
|
205 |
break;
|
206 |
+
// invalid email (or no email at all)
|
207 |
+
case '-100':
|
208 |
+
$error_response = ( ! empty( $error_messages['invalid-email'] ) ) ? $error_messages['invalid-email'] : $subscribe_response['error'];
|
209 |
+
break;
|
210 |
default:
|
211 |
$error_response = ( ! empty( $error_messages['general-error'] ) ) ? $error_messages['general-error'] : $subscribe_response['error'];
|
212 |
break;
|
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.5
|
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.5.1
|
7 |
* Author: YIKES
|
8 |
* Author URI: http://www.yikesinc.com/
|
9 |
* License: GPL-3.0+
|