Creative Mail – Easier WordPress & WooCommerce Email Marketing - Version 1.5.4

Version Description

Download this release

Release Info

Developer constantcontact
Plugin Icon 128x128 Creative Mail – Easier WordPress & WooCommerce Email Marketing
Version 1.5.4
Comparing to
See all releases

Code changes from version 1.5.3 to 1.5.4

CHANGELOG.md CHANGED
@@ -1,157 +1,162 @@
1
  Changelog
2
  =========
 
 
 
 
 
3
  #### 1.5.3 - README update
4
  - Removing broken Youtube video link
5
 
6
- #### 1.5.2 - March 22 2022
7
  - Small bug fix for PHP versions previous to 7.1
8
 
9
- #### 1.5.1 - March 22 2022
10
  - Fix outdated PHP classes
11
 
12
- #### 1.5.0 - March 1 2022
13
  - Fix WooCommerce product lists
14
  - WooCommerce order workflows improved.
15
  - Improved contact management
16
 
17
- #### 1.4.9 - January 3 2022
18
  - Add Flag Customer Orders
19
  - Fix phone numbers should now be synced successfully and contacts will only be subscribed if the 'acceptance' checkbox is checked
20
  - Fix error after Order Completed Trigger
21
 
22
- #### 1.4.8 - December 1 2021
23
  - Redirect to main Creativ Email templates page when user has abandoned cart template deactivated.
24
  - Fix sync error with contact form 7
25
  - Added automation trigger for customer buying products
26
 
27
- #### 1.4.7 - October 7 2021
28
  - Fix currency type being shown in "Abandoned Cart" emails for WooCommerce.
29
 
30
- #### 1.4.6 - September 23 2021
31
  - Add phone number handling for Jetpack Forms. Bug fixes.
32
 
33
- #### 1.4.5 - September 2 2021
34
- - This version contains a fix for Creative mail customers who also use the Bluehost Websitebuilder functionality to build their WordPress site.
35
 
36
- #### 1.4.4 - August 19 2021
37
  - Add support for 'return to shop' urls
38
  - Bug fixes
39
 
40
- #### 1.4.3 - August 12 2021
41
  - Updated brand name.
42
 
43
- #### 1.4.2 - July 19 2021
44
  - Fixed a crash when enabling the Elementor contact sync.
45
 
46
- #### 1.4.1 - July 12 2021
47
  - Fixed several bugs
48
 
49
  #### 1.4.0 - June 15 2021
50
  - Added gutenberg contact form block CreativeMail
51
 
52
- #### 1.3.9 - May 26 2021
53
  - Include notice when you have enabled a password protection plugin.
54
 
55
- #### 1.3.8 - May 18 2021
56
  - Fixes an issue with WooCommerce recommendations.
57
 
58
- #### 1.3.7 - May 18 2021
59
  - Fixes an issue specific to PHP 7.4
60
 
61
- #### 1.3.6 - May 11 2021
62
  - Improvements for the WooCommerce integration.
63
  - Add support for Formidable.
64
  - Add support for Abandoned cart emails in WooCommerce.
65
 
66
- #### 1.3.5 - March 22 2021
67
  - Addresses two small issues where some relative URLs would not work for WP installs in subdirectories.
68
 
69
- #### 1.3.4 - March 16 2021
70
  - Improved initial contact sync: we can now import all your contacts without any limits!
71
 
72
- #### 1.3.3 - March 3 2021
73
  - UI Improvements on the settings screen.
74
  - Direct access to Creative Mail features from the left side nav in WP Admin.
75
 
76
- #### 1.3.2 - February 17 2021
77
  - Fixes an issue where the contact sync might cause a critical error
78
 
79
- #### 1.3.1 - January 20 2021
80
  - Add the ability to show the amount of recovered revenue via abandoned carts
81
 
82
- #### 1.3.0 - January 6 2021
83
  - Support for abandoned cart emails
84
 
85
- #### 1.2.4 - December 16 2020
86
  - Introduces a 'Reset' button on the settings page for accounts that are stuck.
87
 
88
- #### 1.2.3 - December 7 2020
89
  - Fixes an issue where the banner would show up again after being dismissed.
90
  - Support WordPress 5.6
91
 
92
  #### 1.2.2 - November 12 2020
93
- - Introduction of multi step automations.
94
  - Fixes a couple of small issues in the CreativeMail widgets.
95
 
96
- #### 1.2.1 - November 10 2020
97
  - Fixes an issue where some users would experience an issue where our UI was blocked by pop-up blockers.
98
 
99
- #### 1.2.0 - November 5 2020
100
  - Context aware notifications
101
  - Add support for Ninja forms
102
  - Add support for Caldera forms
103
 
104
- #### 1.1.10 - October 27 2020
105
  - Fixes an issue where some WooCommerce Notification emails might not be delivered.
106
 
107
- #### 1.1.9 - October 26 2020
108
  - Fixes an issue that would not allow you to open the dashboard again after you opened it once.
109
 
110
- #### 1.1.8 - October 8 2020
111
  - Fixes an issue that could cause a crash for some users.
112
 
113
- #### 1.1.7 - October 5 2020
114
  - Add support for Elementor forms.
115
 
116
- #### 1.1.6 - September 21 2020
117
  - Add option to refresh the SSO url without reloading the entire page;
118
  - Add support for opt-in checkbox in the WooCommerce checkout flow;
119
  - Automatically take the user to the plugin after activating the plugin.
120
 
121
- #### 1.1.5 - September 9 2020
122
  - Fixes an issue where order notification emails would not always go out.
123
 
124
- #### 1.1.4 - September 2 2020
125
  - Minor improvements
126
 
127
- #### 1.1.3 - September 1 2020
128
  - Implemented a new design
129
 
130
- #### 1.1.2 - August 31 2020
131
  - Fixes a bug that would cause the plugin to throw an exception when installing through the plugin management api.
132
  - Add support for beta versions of Jetpack.
133
 
134
- #### 1.1.1 - August 27 2020
135
  - Fixes a bug that would cache API responses
136
 
137
- #### 1.1.0 - August 26 2020
138
  - Add support for WooCommerce emails
139
  - Add support for JetPack forms
140
  - Add support for WPForms Lite
141
  - Add support for Gravity forms
142
 
143
- #### 1.0.4 - July 23 2020
144
  - Small fixes in the plugin readme.
145
  - Added compatibility with PHP 5.6
146
 
147
- #### 1.0.3 - July 16 2020
148
  - Small fixes in the plugin readme.
149
 
150
- #### 1.0.2 - July 16 2020
151
  - Small fixes in the plugin readme.
152
 
153
- #### 1.0.1 - July 16 2020
154
  - Fixes an issue where the "Let's get started" button needed to be clicked twice in some cases.
155
 
156
- #### 1.0.0 - July 16 2020
157
  - Initial version of the plugin
1
  Changelog
2
  =========
3
+
4
+ #### 1.5.4 - September 5th, 2022
5
+ - Migration to WordPress version 6.0.2
6
+ - Checkout mail templates update
7
+
8
  #### 1.5.3 - README update
9
  - Removing broken Youtube video link
10
 
11
+ #### 1.5.2 - March 22, 2022
12
  - Small bug fix for PHP versions previous to 7.1
13
 
14
+ #### 1.5.1 - March 22, 2022
15
  - Fix outdated PHP classes
16
 
17
+ #### 1.5.0 - March 1, 2022
18
  - Fix WooCommerce product lists
19
  - WooCommerce order workflows improved.
20
  - Improved contact management
21
 
22
+ #### 1.4.9 - January 3, 2022
23
  - Add Flag Customer Orders
24
  - Fix phone numbers should now be synced successfully and contacts will only be subscribed if the 'acceptance' checkbox is checked
25
  - Fix error after Order Completed Trigger
26
 
27
+ #### 1.4.8 - December 1, 2021
28
  - Redirect to main Creativ Email templates page when user has abandoned cart template deactivated.
29
  - Fix sync error with contact form 7
30
  - Added automation trigger for customer buying products
31
 
32
+ #### 1.4.7 - October 7, 2021
33
  - Fix currency type being shown in "Abandoned Cart" emails for WooCommerce.
34
 
35
+ #### 1.4.6 - September 23, 2021
36
  - Add phone number handling for Jetpack Forms. Bug fixes.
37
 
38
+ #### 1.4.5 - September 2, 2021
39
+ - This version contains a fix for Creative mail customers who also use the Bluehost WebsiteBuilder functionality to build their WordPress site.
40
 
41
+ #### 1.4.4 - August 19, 2021
42
  - Add support for 'return to shop' urls
43
  - Bug fixes
44
 
45
+ #### 1.4.3 - August 12, 2021
46
  - Updated brand name.
47
 
48
+ #### 1.4.2 - July 19, 2021
49
  - Fixed a crash when enabling the Elementor contact sync.
50
 
51
+ #### 1.4.1 - July 12, 2021
52
  - Fixed several bugs
53
 
54
  #### 1.4.0 - June 15 2021
55
  - Added gutenberg contact form block CreativeMail
56
 
57
+ #### 1.3.9 - May 26, 2021
58
  - Include notice when you have enabled a password protection plugin.
59
 
60
+ #### 1.3.8 - May 18, 2021
61
  - Fixes an issue with WooCommerce recommendations.
62
 
63
+ #### 1.3.7 - May 18, 2021
64
  - Fixes an issue specific to PHP 7.4
65
 
66
+ #### 1.3.6 - May 11, 2021
67
  - Improvements for the WooCommerce integration.
68
  - Add support for Formidable.
69
  - Add support for Abandoned cart emails in WooCommerce.
70
 
71
+ #### 1.3.5 - March 22, 2021
72
  - Addresses two small issues where some relative URLs would not work for WP installs in subdirectories.
73
 
74
+ #### 1.3.4 - March 16, 2021
75
  - Improved initial contact sync: we can now import all your contacts without any limits!
76
 
77
+ #### 1.3.3 - March 3, 2021
78
  - UI Improvements on the settings screen.
79
  - Direct access to Creative Mail features from the left side nav in WP Admin.
80
 
81
+ #### 1.3.2 - February 17, 2021
82
  - Fixes an issue where the contact sync might cause a critical error
83
 
84
+ #### 1.3.1 - January 20, 2021
85
  - Add the ability to show the amount of recovered revenue via abandoned carts
86
 
87
+ #### 1.3.0 - January 6, 2021
88
  - Support for abandoned cart emails
89
 
90
+ #### 1.2.4 - December 16, 2020
91
  - Introduces a 'Reset' button on the settings page for accounts that are stuck.
92
 
93
+ #### 1.2.3 - December 7, 2020
94
  - Fixes an issue where the banner would show up again after being dismissed.
95
  - Support WordPress 5.6
96
 
97
  #### 1.2.2 - November 12 2020
98
+ - Introduction of multistep automations.
99
  - Fixes a couple of small issues in the CreativeMail widgets.
100
 
101
+ #### 1.2.1 - November 10, 2020
102
  - Fixes an issue where some users would experience an issue where our UI was blocked by pop-up blockers.
103
 
104
+ #### 1.2.0 - November 5, 2020
105
  - Context aware notifications
106
  - Add support for Ninja forms
107
  - Add support for Caldera forms
108
 
109
+ #### 1.1.10 - October 27, 2020
110
  - Fixes an issue where some WooCommerce Notification emails might not be delivered.
111
 
112
+ #### 1.1.9 - October 26, 2020
113
  - Fixes an issue that would not allow you to open the dashboard again after you opened it once.
114
 
115
+ #### 1.1.8 - October 8, 2020
116
  - Fixes an issue that could cause a crash for some users.
117
 
118
+ #### 1.1.7 - October 5, 2020
119
  - Add support for Elementor forms.
120
 
121
+ #### 1.1.6 - September 21, 2020
122
  - Add option to refresh the SSO url without reloading the entire page;
123
  - Add support for opt-in checkbox in the WooCommerce checkout flow;
124
  - Automatically take the user to the plugin after activating the plugin.
125
 
126
+ #### 1.1.5 - September 9, 2020
127
  - Fixes an issue where order notification emails would not always go out.
128
 
129
+ #### 1.1.4 - September 2, 2020
130
  - Minor improvements
131
 
132
+ #### 1.1.3 - September 1, 2020
133
  - Implemented a new design
134
 
135
+ #### 1.1.2 - August 31, 2020
136
  - Fixes a bug that would cause the plugin to throw an exception when installing through the plugin management api.
137
  - Add support for beta versions of Jetpack.
138
 
139
+ #### 1.1.1 - August 27, 2020
140
  - Fixes a bug that would cache API responses
141
 
142
+ #### 1.1.0 - August 26, 2020
143
  - Add support for WooCommerce emails
144
  - Add support for JetPack forms
145
  - Add support for WPForms Lite
146
  - Add support for Gravity forms
147
 
148
+ #### 1.0.4 - July 23, 2020
149
  - Small fixes in the plugin readme.
150
  - Added compatibility with PHP 5.6
151
 
152
+ #### 1.0.3 - July 16, 2020
153
  - Small fixes in the plugin readme.
154
 
155
+ #### 1.0.2 - July 16, 2020
156
  - Small fixes in the plugin readme.
157
 
158
+ #### 1.0.1 - July 16, 2020
159
  - Fixes an issue where the "Let's get started" button needed to be clicked twice in some cases.
160
 
161
+ #### 1.0.0 - July 16, 2020
162
  - Initial version of the plugin
README.md CHANGED
@@ -2,14 +2,14 @@
2
  Contributors: Constant Contact
3
  Tags: email, marketing, newsletter, subscribe, contact form, constant contact, crm, automations, ecommerce, promotion, offers, retargeting
4
  Requires at least: 4.6
5
- Tested up to: 5.9
6
- Stable tag: 1.5.3
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
  Requires PHP: 5.6
10
  Website: https://www.creativemail.com
11
  WC requires at least: 3.0.0
12
- WC tested up to: 5.5.0
13
 
14
  Creative Mail was designed specifically for WordPress and WooCommerce.
15
  Our intelligent (and super fun) email editor simplifies email marketing campaign creation and pulls your WordPress blog posts, website images and WooCommerce products right into your email content.
@@ -32,13 +32,13 @@ Turn your WooCommerce store and your WordPress site into efficient marketing eng
32
  - **Beautiful Transactional Emails:** Standard WooCommerce triggered emails can be replaced to match your branding and style. Build one, and then all your other WooCommerce emails managed by Creative will inherit the same branded look. Hey, style matters.
33
  - **Jetpack Forms Integration:** Collect, sync, and manage opt-in subscribers directly from Jetpack forms into Creative Mail.
34
  - **Build Better Branding:** Creative Mail includes our free LogoBuilder and image editing suite to enhance your brand.
35
- - **Amazing Stock Images:** You get free access to the completely integrated photo library (in addition to your own WordPress media library) to make amazing email marketing campaigns with award winning images.
36
  - **Get Better Deliverability:** Other email marketing solutions require complex SMTP solutions, external gateways or have you sending from their less than stellar IPs. As a result, your emails can get bounced or never delivered. Creative Mail is an all-in-one solution that uses Constant Contact’s rock solid infrastructure, for superior deliverability. Boom! ‘nuff said.
37
  - **Live Support:** With our paid plans (Awesome & Ultimate) you get access to phone and chat support to help you get answers from real live, helpful humans. Imagine that!
38
 
39
  ### [OPT-IN EMAIL FORMS](https://www.creativemail.com):
40
  - **Jetpack & WordPress Website Forms:** Creative Mail detects the current website forms used on your site, and automatically adds contacts to your email marketing lists. Automagically awesome!
41
- - **JMML Newsletter Form:** Creative Mail and Jetpack now include a JMML (join my mailing list) Newsletter Signup form. When activated, contacts who sign up for your Newsletter through the JMML form are brought right into your Newsletter email marketing list. Easy peasy.
42
 
43
  ### [EMAIL AUTOMATIONS](https://www.creativemail.com):
44
  - **Scheduled Sends:** Schedule the time and date of outgoing email marketing campaigns based on your business or organization's preferences.
@@ -63,7 +63,7 @@ Turn your WooCommerce store and your WordPress site into efficient marketing eng
63
  - **AI Emails:** Forget templates, let our A.I. build your email marketing campaigns for you. Pull in WordPress posts or WooCommerce products for sale and you’re good to go. Let our robots do your bidding!
64
  - **Email Campaign Creation:** Build your email marketing campaigns in seconds from your WordPress admin dashboard.
65
  - **Awesome Deliverability:** All email marketing campaigns are sent and delivered by the award-winning power of Constant Contact technology. We got you.
66
- - **Automated Email Marketing:** Send multi-step email campaigns automatically, with triggers you define, whether that’s based on time or behavioral actions. (Coming Soon)
67
 
68
  ### [EMAIL LIST MANAGEMENT](https://www.creativemail.com):
69
  - **Contact List Growth:** Creative Mail collects leads from Jetpack forms or the top WordPress lead capture forms and adds them directly to your email lists.
@@ -72,11 +72,11 @@ Turn your WooCommerce store and your WordPress site into efficient marketing eng
72
 
73
  ## CREATIVE MAIL IS:
74
  1. Incredibly easy WordPress email marketing
75
- 1. Deeply connected to your website & WooCommerce store
76
- 1. Accessed from within your WP Admin Dashboard
77
- 1. Automatically syncing your contacts and building your marketing lists
78
- 1. Powered by the reliability superior deliverability of Constant Contact
79
- 1. Fun, which makes life way better
80
 
81
  ## TERMS OF SERVICE & PRIVACY NOTICE
82
  On behalf of our lawyers (seriously, they’re nice people), please feel free to review our:
@@ -85,7 +85,7 @@ Creative Mail by Constant Contact [Terms of Service](https://www.constantcontact
85
  Creative Mail by Constant Contact [Privacy Notice](https://www.endurance.com/privacy/privacy)
86
 
87
  == Screenshots ==
88
- 1. Your all in one dashboard
89
  2. Design awesome email campaigns with the visual editor
90
  3. Manage your contacts and email lists, all in one place
91
  4. Let Creative Mail handle your WooCommerce emails
@@ -93,15 +93,16 @@ Creative Mail by Constant Contact [Privacy Notice](https://www.endurance.com/pri
93
  6. Enhance your brand with LogoBuilder
94
 
95
  == Changelog ==
 
96
  * 1.5.3 - README update
97
  * 1.5.2 - Small bug fix for PHP versions previous to 7.1
98
  * 1.5.1 - Fix outdated PHP classes
99
  * 1.5.0 - Fix WooCommerce product lists, improved WooCommerce order workflows and improved contact management.
100
- * 1.4.9 - Fixes regarding WooCoomerce and Contact Sync Updates.
101
- * 1.4.8 - Redirect to main Creativ Email templates page when user has abandoned cart template deactivated. Fix sync error with contact form 7. Added automation trigger for customer buying products.
102
  * 1.4.7 - Fix currency type being shown in "Abandoned Cart" emails for WooCommerce.
103
  * 1.4.6 - Add phone number handling for Jetpack Forms. Bug fixes.
104
- * 1.4.5 - This version contains a fix for Creative mail customers who also use the Bluehost Websitebuilder functionality to build their WordPress site.
105
  * 1.4.4 - Add support for 'return to shop' urls
106
  * 1.4.3 - Updated brand name.
107
  * 1.4.2 - Fixed a crash when enabling the Elementor contact sync.
@@ -119,6 +120,6 @@ Creative Mail by Constant Contact [Privacy Notice](https://www.endurance.com/pri
119
  * 1.3.0 - Support for abandoned cart emails.
120
  * 1.2.4 - Introduces a 'Reset' button on the settings page for accounts that are stuck.
121
  * 1.2.3 - Fixes an issue where the banner would show up again after being dismissed.
122
- * 1.2.2 - Introduction of multi step automations and fixes a couple of small issues in the CreativeMail widgets
123
  * 1.2.1 - Fixes an issue where some users would experience an issue where our UI was blocked by pop-up blockers.
124
  * 1.2.0 - Context aware notifications, add support for Ninja forms, add support for Caldera forms
2
  Contributors: Constant Contact
3
  Tags: email, marketing, newsletter, subscribe, contact form, constant contact, crm, automations, ecommerce, promotion, offers, retargeting
4
  Requires at least: 4.6
5
+ Tested up to: 6.0.2
6
+ Stable tag: 1.5.4
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
  Requires PHP: 5.6
10
  Website: https://www.creativemail.com
11
  WC requires at least: 3.0.0
12
+ WC tested up to: 6.8.2
13
 
14
  Creative Mail was designed specifically for WordPress and WooCommerce.
15
  Our intelligent (and super fun) email editor simplifies email marketing campaign creation and pulls your WordPress blog posts, website images and WooCommerce products right into your email content.
32
  - **Beautiful Transactional Emails:** Standard WooCommerce triggered emails can be replaced to match your branding and style. Build one, and then all your other WooCommerce emails managed by Creative will inherit the same branded look. Hey, style matters.
33
  - **Jetpack Forms Integration:** Collect, sync, and manage opt-in subscribers directly from Jetpack forms into Creative Mail.
34
  - **Build Better Branding:** Creative Mail includes our free LogoBuilder and image editing suite to enhance your brand.
35
+ - **Amazing Stock Images:** You get free access to the completely integrated photo library (in addition to your own WordPress media library) to make amazing email marketing campaigns with award-winning images.
36
  - **Get Better Deliverability:** Other email marketing solutions require complex SMTP solutions, external gateways or have you sending from their less than stellar IPs. As a result, your emails can get bounced or never delivered. Creative Mail is an all-in-one solution that uses Constant Contact’s rock solid infrastructure, for superior deliverability. Boom! ‘nuff said.
37
  - **Live Support:** With our paid plans (Awesome & Ultimate) you get access to phone and chat support to help you get answers from real live, helpful humans. Imagine that!
38
 
39
  ### [OPT-IN EMAIL FORMS](https://www.creativemail.com):
40
  - **Jetpack & WordPress Website Forms:** Creative Mail detects the current website forms used on your site, and automatically adds contacts to your email marketing lists. Automagically awesome!
41
+ - **JMML Newsletter Form:** Creative Mail and Jetpack now include a JMML (join my mailing list) Newsletter Signup form. When activated, contacts who sign up for your Newsletter through the JMML form are brought right into your Newsletter email marketing list. Easy-peasy.
42
 
43
  ### [EMAIL AUTOMATIONS](https://www.creativemail.com):
44
  - **Scheduled Sends:** Schedule the time and date of outgoing email marketing campaigns based on your business or organization's preferences.
63
  - **AI Emails:** Forget templates, let our A.I. build your email marketing campaigns for you. Pull in WordPress posts or WooCommerce products for sale and you’re good to go. Let our robots do your bidding!
64
  - **Email Campaign Creation:** Build your email marketing campaigns in seconds from your WordPress admin dashboard.
65
  - **Awesome Deliverability:** All email marketing campaigns are sent and delivered by the award-winning power of Constant Contact technology. We got you.
66
+ - **Automated Email Marketing:** Send multistep email campaigns automatically, with triggers you define, whether that’s based on time or behavioral actions. (Coming Soon)
67
 
68
  ### [EMAIL LIST MANAGEMENT](https://www.creativemail.com):
69
  - **Contact List Growth:** Creative Mail collects leads from Jetpack forms or the top WordPress lead capture forms and adds them directly to your email lists.
72
 
73
  ## CREATIVE MAIL IS:
74
  1. Incredibly easy WordPress email marketing
75
+ 2. Deeply connected to your website & WooCommerce store
76
+ 3. Accessed from within your WP Admin Dashboard
77
+ 4. Automatically syncing your contacts and building your marketing lists
78
+ 5. Powered by the reliability superior deliverability of Constant Contact
79
+ 6. Fun, which makes life way better
80
 
81
  ## TERMS OF SERVICE & PRIVACY NOTICE
82
  On behalf of our lawyers (seriously, they’re nice people), please feel free to review our:
85
  Creative Mail by Constant Contact [Privacy Notice](https://www.endurance.com/privacy/privacy)
86
 
87
  == Screenshots ==
88
+ 1. Your all-in-one dashboard
89
  2. Design awesome email campaigns with the visual editor
90
  3. Manage your contacts and email lists, all in one place
91
  4. Let Creative Mail handle your WooCommerce emails
93
  6. Enhance your brand with LogoBuilder
94
 
95
  == Changelog ==
96
+ * 1.5.4 - Migration to WordPress version 6.0.2 and Checkout mail templates update
97
  * 1.5.3 - README update
98
  * 1.5.2 - Small bug fix for PHP versions previous to 7.1
99
  * 1.5.1 - Fix outdated PHP classes
100
  * 1.5.0 - Fix WooCommerce product lists, improved WooCommerce order workflows and improved contact management.
101
+ * 1.4.9 - Fixes regarding WooCommerce and Contact Sync Updates.
102
+ * 1.4.8 - Redirect to main CreativEmail templates page when user has abandoned cart template deactivated. Fix sync error with contact form 7. Added automation trigger for customer buying products.
103
  * 1.4.7 - Fix currency type being shown in "Abandoned Cart" emails for WooCommerce.
104
  * 1.4.6 - Add phone number handling for Jetpack Forms. Bug fixes.
105
+ * 1.4.5 - This version contains a fix for Creative mail customers who also use the Bluehost WebsiteBuilder functionality to build their WordPress site.
106
  * 1.4.4 - Add support for 'return to shop' urls
107
  * 1.4.3 - Updated brand name.
108
  * 1.4.2 - Fixed a crash when enabling the Elementor contact sync.
120
  * 1.3.0 - Support for abandoned cart emails.
121
  * 1.2.4 - Introduces a 'Reset' button on the settings page for accounts that are stuck.
122
  * 1.2.3 - Fixes an issue where the banner would show up again after being dismissed.
123
+ * 1.2.2 - Introduction of multistep automations and fixes a couple of small issues in the CreativeMail widgets
124
  * 1.2.1 - Fixes an issue where some users would experience an issue where our UI was blocked by pop-up blockers.
125
  * 1.2.0 - Context aware notifications, add support for Ninja forms, add support for Caldera forms
creative-mail-plugin.php CHANGED
@@ -9,10 +9,10 @@
9
  * Plugin URI: https://wordpress.org/plugins/creative-mail-by-constant-contact/
10
  * Description: Free email marketing designed specifically for WordPress, Jetpack and WooCommerce. Send newsletters, promotions, updates and transactional e-commerce emails. Simple and easy, powered by Constant Contact’s rock solid reliability.
11
  * Author: Constant Contact
12
- * Version: 1.5.3
13
  * Author URI: https://www.constantcontact.com
14
  * WC requires at least: 3.0.0
15
- * WC tested up to: 5.1.0
16
  */
17
  use CreativeMail\CreativeMail;
18
  use CreativeMail\Blocks\LoadBlock;
@@ -27,7 +27,7 @@ function _load_ce4wp_plugin()
27
  define('CE4WP_PLUGIN_DIR', __DIR__ . '/');
28
  define('CE4WP_PLUGIN_URL', plugin_dir_url(__FILE__) . '/');
29
  define('CE4WP_PLUGIN_FILE', __FILE__);
30
- define('CE4WP_PLUGIN_VERSION', '1.5.2');
31
  define('CE4WP_INSTANCE_UUID_KEY', 'ce4wp_instance_uuid');
32
  define('CE4WP_INSTANCE_HANDSHAKE_TOKEN', 'ce4wp_handshake_token');
33
  define('CE4WP_INSTANCE_HANDSHAKE_EXPIRATION', 'ce4wp_handshake_expiration');
@@ -44,7 +44,7 @@ function _load_ce4wp_plugin()
44
  define('CE4WP_APP_GATEWAY_URL', 'https://app-gateway.creativemail.com/');
45
  define('CE4WP_APP_URL', 'https://app.creativemail.com/');
46
  define('CE4WP_ENVIRONMENT', 'PRODUCTION');
47
- define('CE4WP_BUILD_NUMBER', '1652');
48
  define('CE4WP_RAYGUN_PHP_KEY', 'Z85xL3mkgnW13Ri9DajGUg');
49
  define('CE4WP_BATCH_SIZE', 500);
50
  define('CE4WP_WC_API_KEY_ID', 'ce4wp_woocommerce_api_key_id');
@@ -91,8 +91,8 @@ register_activation_hook(__FILE__, 'ce4wp_activate');
91
  register_deactivation_hook(__FILE__, 'ce4wp_deactivate');
92
 
93
  // Add on submit to subscribe buttons
94
- add_action('init', 'wpse_add_front_end_on_submit');
95
- function wpse_add_front_end_on_submit()
96
  {
97
  wp_enqueue_script(
98
  'ce4wp_form_submit',
9
  * Plugin URI: https://wordpress.org/plugins/creative-mail-by-constant-contact/
10
  * Description: Free email marketing designed specifically for WordPress, Jetpack and WooCommerce. Send newsletters, promotions, updates and transactional e-commerce emails. Simple and easy, powered by Constant Contact’s rock solid reliability.
11
  * Author: Constant Contact
12
+ * Version: 1.5.4
13
  * Author URI: https://www.constantcontact.com
14
  * WC requires at least: 3.0.0
15
+ * WC tested up to: 6.8.2
16
  */
17
  use CreativeMail\CreativeMail;
18
  use CreativeMail\Blocks\LoadBlock;
27
  define('CE4WP_PLUGIN_DIR', __DIR__ . '/');
28
  define('CE4WP_PLUGIN_URL', plugin_dir_url(__FILE__) . '/');
29
  define('CE4WP_PLUGIN_FILE', __FILE__);
30
+ define('CE4WP_PLUGIN_VERSION', '1.5.4');
31
  define('CE4WP_INSTANCE_UUID_KEY', 'ce4wp_instance_uuid');
32
  define('CE4WP_INSTANCE_HANDSHAKE_TOKEN', 'ce4wp_handshake_token');
33
  define('CE4WP_INSTANCE_HANDSHAKE_EXPIRATION', 'ce4wp_handshake_expiration');
44
  define('CE4WP_APP_GATEWAY_URL', 'https://app-gateway.creativemail.com/');
45
  define('CE4WP_APP_URL', 'https://app.creativemail.com/');
46
  define('CE4WP_ENVIRONMENT', 'PRODUCTION');
47
+ define('CE4WP_BUILD_NUMBER', '1766');
48
  define('CE4WP_RAYGUN_PHP_KEY', 'Z85xL3mkgnW13Ri9DajGUg');
49
  define('CE4WP_BATCH_SIZE', 500);
50
  define('CE4WP_WC_API_KEY_ID', 'ce4wp_woocommerce_api_key_id');
91
  register_deactivation_hook(__FILE__, 'ce4wp_deactivate');
92
 
93
  // Add on submit to subscribe buttons
94
+ add_action('init', 'ce4wp_add_front_end_on_submit');
95
+ function ce4wp_add_front_end_on_submit()
96
  {
97
  wp_enqueue_script(
98
  'ce4wp_form_submit',
readme.txt CHANGED
@@ -2,14 +2,14 @@
2
  Contributors: Constant Contact
3
  Tags: email, marketing, newsletter, subscribe, contact form, constant contact, crm, automations, ecommerce, promotion, offers, retargeting
4
  Requires at least: 4.6
5
- Tested up to: 5.9
6
- Stable tag: 1.5.3
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
  Requires PHP: 5.6
10
  Website: https://www.creativemail.com
11
  WC requires at least: 3.0.0
12
- WC tested up to: 5.5.0
13
 
14
  Creative Mail was designed specifically for WordPress and WooCommerce.
15
  Our intelligent (and super fun) email editor simplifies email marketing campaign creation and pulls your WordPress blog posts, website images and WooCommerce products right into your email content.
@@ -40,12 +40,12 @@ Turn your WooCommerce store and your WordPress site into efficient marketing eng
40
  - **Beautiful Transactional Emails:** Standard WooCommerce triggered emails can be replaced to match your branding and style. Build one, and then all your other WooCommerce emails managed by Creative will inherit the same branded look. Hey, style matters.
41
  - **Jetpack Forms Integration:** Collect, sync, and manage opt-in subscribers directly from Jetpack forms into Creative Mail.
42
  - **Build Better Branding:** Creative Mail includes our free LogoBuilder and image editing suite to enhance your brand.
43
- - **Amazing Stock Images:** You get free access to the completely integrated photo library (in addition to your own WordPress media library) to make amazing email marketing campaigns with award winning images.
44
  - **Get Better Deliverability:** Other email marketing solutions require complex SMTP solutions, external gateways or have you sending from their less than stellar IPs. As a result, your emails can get bounced or never delivered. Creative Mail is an all-in-one solution that uses Constant Contact’s rock solid infrastructure, for superior deliverability. Boom! ‘nuff said.
45
  - **Live Support:** With our paid plans (Awesome & Ultimate) you get access to phone and chat support to help you get answers from real live, helpful humans. Imagine that!
46
 
47
  ### [OPT-IN EMAIL FORMS](https://www.creativemail.com):
48
- - **Jetpack Newsletter Form:** Jetpack has a JMML (join my mailing list) Newsletter Signup form. When activated, contacts who sign up for your Newsletter through the Jetpack form are brought right into your Newsletter email marketing list. Easy peasy.
49
  - **Other WordPress Website Forms:** Creative Mail detects the current website forms used on your site, and automatically adds contacts to your email marketing lists. Automagically awesome!
50
  - **Creative Mail Form:** If you are not using a form on your site, you can easily add your Creative Mail Gutenberg form to start collecting email addresses of your site visitors
51
 
@@ -71,10 +71,10 @@ Turn your WooCommerce store and your WordPress site into efficient marketing eng
71
  - **Import & Export Via CSV:** Import bulk email marketing lists (limits may apply), add subscribers one by one, or export your contacts into a CSV file.
72
 
73
  ### [CAMPAIGNS](https://www.creativemail.com):
74
- - **AI Emails:** Forget templates, let our A.I. build your email marketing campaigns for you. Pull in WordPress posts or WooCommerce products for sale and you’re good to go. Let our robots do your bidding!
75
  - **Email Campaign Creation:** Build your email marketing campaigns in seconds from your WordPress admin dashboard.
76
  - **Awesome Deliverability:** All email marketing campaigns are sent and delivered by the award-winning power of Constant Contact technology. We got you.
77
- - **Automated Email Marketing:** Send multi-step email campaigns automatically, with triggers you define, whether that’s based on time, a customer birthday or behavioral actions. Create a flow to welcome your customers and send a special discount and reminder on their birthday.
78
 
79
  ### [EMAIL LIST MANAGEMENT](https://www.creativemail.com):
80
  - **Contact List Growth:** Creative Mail collects leads from Jetpack forms or the top WordPress lead capture forms and adds them directly to your email lists.
@@ -84,7 +84,7 @@ Turn your WooCommerce store and your WordPress site into efficient marketing eng
84
  ### ADD ONS
85
  - **Social Campaigns:** Connect your social media accounts with your Creative Mail account to share your newsletters with your followers on social.
86
  - **Marketing Calendar:** With your socials connected we give you an overview of all the newsletters and posts that you’ve sent and scheduled. An easy overview to engage with your audience.
87
- - **Booking:** Set up Bookings for your business with the Bookingstool. Give clients and customers an easy, quick way to set up appointments with you.
88
  - **LogoBuilder:** Create an amazing logo for your business or social with LogoBuilder and add it to your email campaigns.
89
 
90
  ## TERMS OF SERVICE & PRIVACY NOTICE
@@ -94,7 +94,7 @@ Creative Mail by Constant Contact [Terms of Service](https://www.constantcontact
94
  Creative Mail by Constant Contact [Privacy Notice](https://www.endurance.com/privacy/privacy)
95
 
96
  == Screenshots ==
97
- 1. Your all in one dashboard
98
  2. Design awesome email campaigns with the visual editor
99
  3. Manage your contacts and email lists, all in one place
100
  4. Let Creative Mail handle your WooCommerce emails
@@ -102,15 +102,16 @@ Creative Mail by Constant Contact [Privacy Notice](https://www.endurance.com/pri
102
  6. Enhance your brand with LogoBuilder
103
 
104
  == Changelog ==
 
105
  * 1.5.3 - README update
106
  * 1.5.2 - Small bug fix for PHP versions previous to 7.1
107
  * 1.5.1 - Fix outdated PHP classes
108
  * 1.5.0 - Fix WooCommerce product lists, improved WooCommerce order workflows and improved contact management.
109
- * 1.4.9 - Fixes regarding WooCoomerce and Contact Sync Updates.
110
- * 1.4.8 - Redirect to main Creativ Email templates page when user has abandoned cart template deactivated. Fix sync error with contact form 7. Added automation trigger for customer buying products.
111
  * 1.4.7 - Fix currency type being shown in "Abandoned Cart" emails for WooCommerce.
112
  * 1.4.6 - Add phone number handling for Jetpack Forms. Bug fixes.
113
- * 1.4.5 - This version contains a fix for Creative mail customers who also use the Bluehost Websitebuilder functionality to build their WordPress site.
114
  * 1.4.4 - Add support for 'return to shop' urls
115
  * 1.4.3 - Updated brand name.
116
  * 1.4.2 - Fixed a crash that could occur when using the elementor contact sync.
@@ -130,18 +131,18 @@ Creative Mail by Constant Contact [Privacy Notice](https://www.endurance.com/pri
130
  == Installation ==
131
 
132
  - Go to your admin dashboard
133
- - Click the “Plugins” menu in the left side navigation bar
134
  - Click on “Add New”
135
  - Search for “Creative”
136
  - Click “Install Now”
137
  - Click “Activate”
138
- - You will be redirected to Creative Mail where you can setup your account
139
 
140
  == Frequently Asked Questions ==
141
 
142
  = Requirements =
143
  - Your website or blog must be using WordPress.org version 4.6 or higher on your server.
144
- - The plugin can be installed on regular Wordpress environments and also on WordPress.com sites.
145
 
146
  = What does the Creative Mail plugin do? =
147
  The Creative mail plugin allows you to create awesome email marketing campaigns right from your WordPress Admin Dashboard that are all powered by the award-winning & rock-solid reliability of Constant Contact.
2
  Contributors: Constant Contact
3
  Tags: email, marketing, newsletter, subscribe, contact form, constant contact, crm, automations, ecommerce, promotion, offers, retargeting
4
  Requires at least: 4.6
5
+ Tested up to: 6.0.2
6
+ Stable tag: 1.5.4
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
  Requires PHP: 5.6
10
  Website: https://www.creativemail.com
11
  WC requires at least: 3.0.0
12
+ WC tested up to: 6.8.2
13
 
14
  Creative Mail was designed specifically for WordPress and WooCommerce.
15
  Our intelligent (and super fun) email editor simplifies email marketing campaign creation and pulls your WordPress blog posts, website images and WooCommerce products right into your email content.
40
  - **Beautiful Transactional Emails:** Standard WooCommerce triggered emails can be replaced to match your branding and style. Build one, and then all your other WooCommerce emails managed by Creative will inherit the same branded look. Hey, style matters.
41
  - **Jetpack Forms Integration:** Collect, sync, and manage opt-in subscribers directly from Jetpack forms into Creative Mail.
42
  - **Build Better Branding:** Creative Mail includes our free LogoBuilder and image editing suite to enhance your brand.
43
+ - **Amazing Stock Images:** You get free access to the completely integrated photo library (in addition to your own WordPress media library) to make amazing email marketing campaigns with award-winning images.
44
  - **Get Better Deliverability:** Other email marketing solutions require complex SMTP solutions, external gateways or have you sending from their less than stellar IPs. As a result, your emails can get bounced or never delivered. Creative Mail is an all-in-one solution that uses Constant Contact’s rock solid infrastructure, for superior deliverability. Boom! ‘nuff said.
45
  - **Live Support:** With our paid plans (Awesome & Ultimate) you get access to phone and chat support to help you get answers from real live, helpful humans. Imagine that!
46
 
47
  ### [OPT-IN EMAIL FORMS](https://www.creativemail.com):
48
+ - **Jetpack Newsletter Form:** Jetpack has a JMML (join my mailing list) Newsletter Signup form. When activated, contacts who sign up for your Newsletter through the Jetpack form are brought right into your Newsletter email marketing list. Easy-peasy.
49
  - **Other WordPress Website Forms:** Creative Mail detects the current website forms used on your site, and automatically adds contacts to your email marketing lists. Automagically awesome!
50
  - **Creative Mail Form:** If you are not using a form on your site, you can easily add your Creative Mail Gutenberg form to start collecting email addresses of your site visitors
51
 
71
  - **Import & Export Via CSV:** Import bulk email marketing lists (limits may apply), add subscribers one by one, or export your contacts into a CSV file.
72
 
73
  ### [CAMPAIGNS](https://www.creativemail.com):
74
+ - **AI Emails:** Forget templates, let our A.I. build your email marketing campaigns for you. Pull in WordPress posts or WooCommerce products for sale, and you’re good to go. Let our robots do your bidding!
75
  - **Email Campaign Creation:** Build your email marketing campaigns in seconds from your WordPress admin dashboard.
76
  - **Awesome Deliverability:** All email marketing campaigns are sent and delivered by the award-winning power of Constant Contact technology. We got you.
77
+ - **Automated Email Marketing:** Send multistep email campaigns automatically, with triggers you define, whether that’s based on time, a customer birthday or behavioral actions. Create a flow to welcome your customers and send a special discount and reminder on their birthday.
78
 
79
  ### [EMAIL LIST MANAGEMENT](https://www.creativemail.com):
80
  - **Contact List Growth:** Creative Mail collects leads from Jetpack forms or the top WordPress lead capture forms and adds them directly to your email lists.
84
  ### ADD ONS
85
  - **Social Campaigns:** Connect your social media accounts with your Creative Mail account to share your newsletters with your followers on social.
86
  - **Marketing Calendar:** With your socials connected we give you an overview of all the newsletters and posts that you’ve sent and scheduled. An easy overview to engage with your audience.
87
+ - **Booking:** Set up Bookings for your business with the Bookings tool. Give clients and customers an easy, quick way to set up appointments with you.
88
  - **LogoBuilder:** Create an amazing logo for your business or social with LogoBuilder and add it to your email campaigns.
89
 
90
  ## TERMS OF SERVICE & PRIVACY NOTICE
94
  Creative Mail by Constant Contact [Privacy Notice](https://www.endurance.com/privacy/privacy)
95
 
96
  == Screenshots ==
97
+ 1. Your all-in-one dashboard
98
  2. Design awesome email campaigns with the visual editor
99
  3. Manage your contacts and email lists, all in one place
100
  4. Let Creative Mail handle your WooCommerce emails
102
  6. Enhance your brand with LogoBuilder
103
 
104
  == Changelog ==
105
+ * 1.5.4 - Migration to WordPress version 6.0.2 and Checkout mail templates update
106
  * 1.5.3 - README update
107
  * 1.5.2 - Small bug fix for PHP versions previous to 7.1
108
  * 1.5.1 - Fix outdated PHP classes
109
  * 1.5.0 - Fix WooCommerce product lists, improved WooCommerce order workflows and improved contact management.
110
+ * 1.4.9 - Fixes regarding WooCommerce and Contact Sync Updates.
111
+ * 1.4.8 - Redirect to main CreativEmail templates page when user has abandoned cart template deactivated. Fix sync error with contact form 7. Added automation trigger for customer buying products.
112
  * 1.4.7 - Fix currency type being shown in "Abandoned Cart" emails for WooCommerce.
113
  * 1.4.6 - Add phone number handling for Jetpack Forms. Bug fixes.
114
+ * 1.4.5 - This version contains a fix for Creative mail customers who also use the Bluehost WebsiteBuilder functionality to build their WordPress site.
115
  * 1.4.4 - Add support for 'return to shop' urls
116
  * 1.4.3 - Updated brand name.
117
  * 1.4.2 - Fixed a crash that could occur when using the elementor contact sync.
131
  == Installation ==
132
 
133
  - Go to your admin dashboard
134
+ - Click the “Plugins” menu on the left side navigation bar
135
  - Click on “Add New”
136
  - Search for “Creative”
137
  - Click “Install Now”
138
  - Click “Activate”
139
+ - You will be redirected to Creative Mail where you can set up your account
140
 
141
  == Frequently Asked Questions ==
142
 
143
  = Requirements =
144
  - Your website or blog must be using WordPress.org version 4.6 or higher on your server.
145
+ - The plugin can be installed on regular WordPress environments and also on WordPress.com sites.
146
 
147
  = What does the Creative Mail plugin do? =
148
  The Creative mail plugin allows you to create awesome email marketing campaigns right from your WordPress Admin Dashboard that are all powered by the award-winning & rock-solid reliability of Constant Contact.
src/Managers/CheckoutManager.php CHANGED
@@ -14,6 +14,7 @@ use CreativeMail\Modules\Contacts\Models\OptActionBy;
14
  use CreativeMail\Models\Order;
15
  use CreativeMail\Models\OrderBilling;
16
  use CreativeMail\Models\RequestItem;
 
17
  use WC_Coupon;
18
  use WC_Order;
19
 
@@ -46,6 +47,8 @@ class CheckoutManager
46
  const BILLING_EMAIL_NO_CONSENT = 'billing_email_no_consent';
47
  const CHECKOUT_UUID_PARAM = 'checkout_uuid = %s';
48
  const COUPONS = 'coupons';
 
 
49
  const PRODUCT_ID = 'product_id';
50
  const VARIATION_ID = 'variation_id';
51
  const QUANTITY = 'quantity';
@@ -191,7 +194,7 @@ class CheckoutManager
191
  CreativeMail::get_instance()->get_database_manager()->remove_checkout_data($checkout_data->checkout_uuid);
192
  }
193
  }
194
- catch (\Exception $e)
195
  {
196
  RaygunManager::get_instance()->exception_handler($e);
197
  }
@@ -218,9 +221,9 @@ class CheckoutManager
218
  return;
219
  }
220
 
221
- // try find recovery date from order meta data
222
  $recovery_date = $order->get_meta( self::META_CHECKOUT_RECOVERED, true );
223
- // Remote post to ce4wp marking checkout as completed/created
224
  $requestItem = new Checkout();
225
  $requestItem->uuid = $uuid;
226
  $requestItem->order_id = $order->get_id();
@@ -455,17 +458,21 @@ class CheckoutManager
455
 
456
  $cart_products = WC()->cart->get_cart();
457
  $cart_coupons = WC()->cart->get_applied_coupons();
 
 
458
 
459
  $checkout_content = [
460
  self::PRODUCTS => array_values( $cart_products ),
461
  self::COUPONS => $cart_coupons,
 
 
462
  ];
463
 
464
  CreativeMail::get_instance()->get_database_manager()->upsert_checkout( $uuid, $user_id, $billing_email, $checkout_content, $current_time );
465
 
466
- // Remote post to ce4wp create or update cart if email is provided
467
  $requestItem = new CheckoutSave();
468
- $requestItem->data = wp_json_encode($this->get_cart_data_for_endpoint( $cart_products, $cart_coupons ) );
469
  $requestItem->uuid = $uuid;
470
  $requestItem->user_id = $user_id;
471
  $requestItem->billing_email = $billing_email;
@@ -483,12 +490,14 @@ class CheckoutManager
483
  *
484
  * @since 1.3.0
485
  */
486
- private function get_cart_data_for_endpoint( $cart_products, $cart_coupons ) {
487
  $data = new CartData();
488
  $data->products = array();
489
  $data->coupons = array();
490
  $data->currency_symbol = get_woocommerce_currency_symbol();
491
  $data->currency = get_woocommerce_currency();
 
 
492
 
493
  $data->user = new User();
494
  try
@@ -565,7 +574,7 @@ class CheckoutManager
565
  }
566
  }
567
  }
568
- catch (\Exception $e)
569
  {
570
  RaygunManager::get_instance()->exception_handler( $e );
571
  }
@@ -639,7 +648,7 @@ class CheckoutManager
639
  // Update totals.
640
  WC()->cart->calculate_totals();
641
 
642
- // Redirect to checkout page.
643
  wp_safe_redirect( wc_get_page_permalink( 'cart' ) );
644
 
645
  exit();
@@ -736,7 +745,7 @@ class CheckoutManager
736
  )
737
  );
738
  }
739
- } catch ( \Exception $e ) {
740
  RaygunManager::get_instance()->exception_handler( $e );
741
  }
742
  }
@@ -752,8 +761,8 @@ class CheckoutManager
752
  )
753
  )
754
  );
755
- } catch ( \Exception $e ) {
756
- // silent
757
  }
758
  }
759
 
@@ -909,7 +918,7 @@ class CheckoutManager
909
  );
910
  }
911
  }
912
- } catch ( \Exception $ex ) {
913
  RaygunManager::get_instance()->exception_handler( $ex );
914
  }
915
 
@@ -956,7 +965,7 @@ class CheckoutManager
956
  'body' => wp_json_encode( $requestItem )
957
  )
958
  );
959
- } catch ( \Exception $e ) {
960
  RaygunManager::get_instance()->exception_handler( $e );
961
  }
962
  }
14
  use CreativeMail\Models\Order;
15
  use CreativeMail\Models\OrderBilling;
16
  use CreativeMail\Models\RequestItem;
17
+ use Exception;
18
  use WC_Coupon;
19
  use WC_Order;
20
 
47
  const BILLING_EMAIL_NO_CONSENT = 'billing_email_no_consent';
48
  const CHECKOUT_UUID_PARAM = 'checkout_uuid = %s';
49
  const COUPONS = 'coupons';
50
+ const SHIPPING_TOTAL = 'shipping_total';
51
+ const SHIPPING_TAXES = 'shipping_taxes';
52
  const PRODUCT_ID = 'product_id';
53
  const VARIATION_ID = 'variation_id';
54
  const QUANTITY = 'quantity';
194
  CreativeMail::get_instance()->get_database_manager()->remove_checkout_data($checkout_data->checkout_uuid);
195
  }
196
  }
197
+ catch (Exception $e)
198
  {
199
  RaygunManager::get_instance()->exception_handler($e);
200
  }
221
  return;
222
  }
223
 
224
+ // Try to find recovery date from order metadata
225
  $recovery_date = $order->get_meta( self::META_CHECKOUT_RECOVERED, true );
226
+ // Remote post to CE4WP marking checkout as completed/created
227
  $requestItem = new Checkout();
228
  $requestItem->uuid = $uuid;
229
  $requestItem->order_id = $order->get_id();
458
 
459
  $cart_products = WC()->cart->get_cart();
460
  $cart_coupons = WC()->cart->get_applied_coupons();
461
+ $shipping_total = WC()->cart->get_shipping_total();
462
+ $shipping_taxes = WC()->cart->get_shipping_taxes();
463
 
464
  $checkout_content = [
465
  self::PRODUCTS => array_values( $cart_products ),
466
  self::COUPONS => $cart_coupons,
467
+ self::SHIPPING_TOTAL => $shipping_total,
468
+ self::SHIPPING_TAXES => $shipping_taxes
469
  ];
470
 
471
  CreativeMail::get_instance()->get_database_manager()->upsert_checkout( $uuid, $user_id, $billing_email, $checkout_content, $current_time );
472
 
473
+ // Remote post to CE4WP create or update cart if email is provided.
474
  $requestItem = new CheckoutSave();
475
+ $requestItem->data = wp_json_encode($this->get_cart_data_for_endpoint( $cart_products, $cart_coupons, $shipping_total, $shipping_taxes ) );
476
  $requestItem->uuid = $uuid;
477
  $requestItem->user_id = $user_id;
478
  $requestItem->billing_email = $billing_email;
490
  *
491
  * @since 1.3.0
492
  */
493
+ private function get_cart_data_for_endpoint( $cart_products, $cart_coupons, $shipping_total=0.00, $shipping_taxes=array() ) {
494
  $data = new CartData();
495
  $data->products = array();
496
  $data->coupons = array();
497
  $data->currency_symbol = get_woocommerce_currency_symbol();
498
  $data->currency = get_woocommerce_currency();
499
+ $data->shipping_total = $shipping_total;
500
+ $data->shipping_taxes = $shipping_taxes;
501
 
502
  $data->user = new User();
503
  try
574
  }
575
  }
576
  }
577
+ catch (Exception $e)
578
  {
579
  RaygunManager::get_instance()->exception_handler( $e );
580
  }
648
  // Update totals.
649
  WC()->cart->calculate_totals();
650
 
651
+ // Redirect to check out page.
652
  wp_safe_redirect( wc_get_page_permalink( 'cart' ) );
653
 
654
  exit();
745
  )
746
  );
747
  }
748
+ } catch ( Exception $e ) {
749
  RaygunManager::get_instance()->exception_handler( $e );
750
  }
751
  }
761
  )
762
  )
763
  );
764
+ } catch ( Exception $e ) {
765
+ RaygunManager::get_instance()->exception_handler( $e );
766
  }
767
  }
768
 
918
  );
919
  }
920
  }
921
+ } catch ( Exception $ex ) {
922
  RaygunManager::get_instance()->exception_handler( $ex );
923
  }
924
 
965
  'body' => wp_json_encode( $requestItem )
966
  )
967
  );
968
+ } catch ( Exception $e ) {
969
  RaygunManager::get_instance()->exception_handler( $e );
970
  }
971
  }
src/Models/CartData.php CHANGED
@@ -34,4 +34,16 @@ class CartData
34
  * @var User
35
  */
36
  public $user;
 
 
 
 
 
 
 
 
 
 
 
 
37
  }
34
  * @var User
35
  */
36
  public $user;
37
+ /**
38
+ * Cart Shipping Total
39
+ *
40
+ * @var float
41
+ */
42
+ public $shipping_total;
43
+ /**
44
+ * Cart Shipping Taxes
45
+ *
46
+ * @var array
47
+ */
48
+ public $shipping_taxes;
49
  }
vendor/autoload.php CHANGED
@@ -4,4 +4,4 @@
4
 
5
  require_once __DIR__ . '/composer/autoload_real.php';
6
 
7
- return ComposerAutoloaderInit70e09938dd3efe3305121f6b4abcb235::getLoader();
4
 
5
  require_once __DIR__ . '/composer/autoload_real.php';
6
 
7
+ return ComposerAutoloaderInit23a51e0a2bd5984936353858b1422529::getLoader();
vendor/composer/autoload_real.php CHANGED
@@ -2,7 +2,7 @@
2
 
3
  // autoload_real.php @generated by Composer
4
 
5
- class ComposerAutoloaderInit70e09938dd3efe3305121f6b4abcb235
6
  {
7
  private static $loader;
8
 
@@ -22,15 +22,15 @@ class ComposerAutoloaderInit70e09938dd3efe3305121f6b4abcb235
22
  return self::$loader;
23
  }
24
 
25
- spl_autoload_register(array('ComposerAutoloaderInit70e09938dd3efe3305121f6b4abcb235', 'loadClassLoader'), true, true);
26
  self::$loader = $loader = new \Composer\Autoload\ClassLoader();
27
- spl_autoload_unregister(array('ComposerAutoloaderInit70e09938dd3efe3305121f6b4abcb235', 'loadClassLoader'));
28
 
29
  $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
30
  if ($useStaticLoader) {
31
  require_once __DIR__ . '/autoload_static.php';
32
 
33
- call_user_func(\Composer\Autoload\ComposerStaticInit70e09938dd3efe3305121f6b4abcb235::getInitializer($loader));
34
  } else {
35
  $map = require __DIR__ . '/autoload_namespaces.php';
36
  foreach ($map as $namespace => $path) {
2
 
3
  // autoload_real.php @generated by Composer
4
 
5
+ class ComposerAutoloaderInit23a51e0a2bd5984936353858b1422529
6
  {
7
  private static $loader;
8
 
22
  return self::$loader;
23
  }
24
 
25
+ spl_autoload_register(array('ComposerAutoloaderInit23a51e0a2bd5984936353858b1422529', 'loadClassLoader'), true, true);
26
  self::$loader = $loader = new \Composer\Autoload\ClassLoader();
27
+ spl_autoload_unregister(array('ComposerAutoloaderInit23a51e0a2bd5984936353858b1422529', 'loadClassLoader'));
28
 
29
  $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
30
  if ($useStaticLoader) {
31
  require_once __DIR__ . '/autoload_static.php';
32
 
33
+ call_user_func(\Composer\Autoload\ComposerStaticInit23a51e0a2bd5984936353858b1422529::getInitializer($loader));
34
  } else {
35
  $map = require __DIR__ . '/autoload_namespaces.php';
36
  foreach ($map as $namespace => $path) {
vendor/composer/autoload_static.php CHANGED
@@ -4,7 +4,7 @@
4
 
5
  namespace Composer\Autoload;
6
 
7
- class ComposerStaticInit70e09938dd3efe3305121f6b4abcb235
8
  {
9
  public static $prefixLengthsPsr4 = array (
10
  'F' =>
@@ -190,10 +190,10 @@ class ComposerStaticInit70e09938dd3efe3305121f6b4abcb235
190
  public static function getInitializer(ClassLoader $loader)
191
  {
192
  return \Closure::bind(function () use ($loader) {
193
- $loader->prefixLengthsPsr4 = ComposerStaticInit70e09938dd3efe3305121f6b4abcb235::$prefixLengthsPsr4;
194
- $loader->prefixDirsPsr4 = ComposerStaticInit70e09938dd3efe3305121f6b4abcb235::$prefixDirsPsr4;
195
- $loader->prefixesPsr0 = ComposerStaticInit70e09938dd3efe3305121f6b4abcb235::$prefixesPsr0;
196
- $loader->classMap = ComposerStaticInit70e09938dd3efe3305121f6b4abcb235::$classMap;
197
 
198
  }, null, ClassLoader::class);
199
  }
4
 
5
  namespace Composer\Autoload;
6
 
7
+ class ComposerStaticInit23a51e0a2bd5984936353858b1422529
8
  {
9
  public static $prefixLengthsPsr4 = array (
10
  'F' =>
190
  public static function getInitializer(ClassLoader $loader)
191
  {
192
  return \Closure::bind(function () use ($loader) {
193
+ $loader->prefixLengthsPsr4 = ComposerStaticInit23a51e0a2bd5984936353858b1422529::$prefixLengthsPsr4;
194
+ $loader->prefixDirsPsr4 = ComposerStaticInit23a51e0a2bd5984936353858b1422529::$prefixDirsPsr4;
195
+ $loader->prefixesPsr0 = ComposerStaticInit23a51e0a2bd5984936353858b1422529::$prefixesPsr0;
196
+ $loader->classMap = ComposerStaticInit23a51e0a2bd5984936353858b1422529::$classMap;
197
 
198
  }, null, ClassLoader::class);
199
  }
vendor/firebase/php-jwt/.github/actions/entrypoint.sh ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/bin/sh -l
2
+
3
+ apt-get update && \
4
+ apt-get install -y --no-install-recommends \
5
+ git \
6
+ zip \
7
+ curl \
8
+ unzip \
9
+ wget
10
+
11
+ curl --silent --show-error https://getcomposer.org/installer | php
12
+ php composer.phar self-update
13
+
14
+ echo "---Installing dependencies ---"
15
+ php composer.phar update
16
+
17
+ echo "---Running unit tests ---"
18
+ vendor/bin/phpunit
vendor/firebase/php-jwt/.github/workflows/tests.yml ADDED
@@ -0,0 +1,77 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: Test Suite
2
+ on:
3
+ push:
4
+ branches:
5
+ - master
6
+ pull_request:
7
+
8
+ jobs:
9
+ test:
10
+ runs-on: ubuntu-latest
11
+ strategy:
12
+ matrix:
13
+ php: [ "5.6", "7.0", "7.1", "7.2", "7.3", "7.4", "8.0" ]
14
+ name: PHP ${{matrix.php }} Unit Test
15
+ steps:
16
+ - uses: actions/checkout@v2
17
+ - name: Setup PHP
18
+ uses: shivammathur/setup-php@v2
19
+ with:
20
+ php-version: ${{ matrix.php }}
21
+ - name: Install Dependencies
22
+ uses: nick-invision/retry@v1
23
+ with:
24
+ timeout_minutes: 10
25
+ max_attempts: 3
26
+ command: composer install
27
+ - name: Run Script
28
+ run: vendor/bin/phpunit
29
+
30
+ # use dockerfiles for old versions of php (setup-php times out for those).
31
+ test_php55:
32
+ name: "PHP 5.5 Unit Test"
33
+ runs-on: ubuntu-latest
34
+ steps:
35
+ - name: Checkout
36
+ uses: actions/checkout@v2
37
+ - name: Run Unit Tests
38
+ uses: docker://php:5.5-cli
39
+ with:
40
+ entrypoint: ./.github/actions/entrypoint.sh
41
+
42
+ test_php54:
43
+ name: "PHP 5.4 Unit Test"
44
+ runs-on: ubuntu-latest
45
+ steps:
46
+ - name: Checkout
47
+ uses: actions/checkout@v2
48
+ - name: Run Unit Tests
49
+ uses: docker://php:5.4-cli
50
+ with:
51
+ entrypoint: ./.github/actions/entrypoint.sh
52
+
53
+ test_php53:
54
+ name: "PHP 5.3 Unit Test"
55
+ runs-on: ubuntu-latest
56
+ steps:
57
+ - name: Checkout
58
+ uses: actions/checkout@v2
59
+ - name: Run Unit Tests
60
+ uses: docker://tomsowerby/php-5.3:cli
61
+ with:
62
+ entrypoint: ./.github/actions/entrypoint.sh
63
+
64
+ style:
65
+ runs-on: ubuntu-latest
66
+ name: PHP Style Check
67
+ steps:
68
+ - uses: actions/checkout@v2
69
+ - name: Setup PHP
70
+ uses: shivammathur/setup-php@v2
71
+ with:
72
+ php-version: "7.0"
73
+ - name: Run Script
74
+ run: |
75
+ composer require friendsofphp/php-cs-fixer
76
+ vendor/bin/php-cs-fixer fix --diff --dry-run .
77
+ vendor/bin/php-cs-fixer fix --rules=native_function_invocation --allow-risky=yes --diff src