Official MailerLite Sign Up Forms - Version 1.1.14

Version Description

  • custom thank you message added
Download this release

Release Info

Developer mailerlite
Plugin Icon 128x128 Official MailerLite Sign Up Forms
Version 1.1.14
Comparing to
See all releases

Code changes from version 1.1.13 to 1.1.14

include/mailerlite-admin.php CHANGED
@@ -198,6 +198,11 @@ class MailerLite_Admin
198
  : __(
199
  'Just simple MailerLite form!', 'mailerlite'
200
  );
 
 
 
 
 
201
  $button_name = isset($_POST['button_name'])
202
  && $_POST['button_name'] != ''
203
  ? sanitize_text_field($_POST['button_name'])
@@ -245,6 +250,7 @@ class MailerLite_Admin
245
  $form_data = array(
246
  'title' => $form_title,
247
  'description' => wpautop($form_description, true),
 
248
  'button' => $button_name,
249
  'language' => $language,
250
  'lists' => $form_lists,
@@ -431,6 +437,9 @@ class MailerLite_Admin
431
  'description' => __(
432
  'Just simple MailerLite form!', 'mailerlite'
433
  ),
 
 
 
434
  'button' => __('Subscribe', 'mailerlite'),
435
  'lists' => array(),
436
  'fields' => array('email' => __('Email', 'mailerlite'))
198
  : __(
199
  'Just simple MailerLite form!', 'mailerlite'
200
  );
201
+ $success_message = isset($_POST['success_message'])
202
+ ? $_POST['success_message']
203
+ : '<span style="color: rgb(51, 153, 102);">' . _e(
204
+ 'Thank you for sign up!', 'mailerlite'
205
+ ) . '</span>';
206
  $button_name = isset($_POST['button_name'])
207
  && $_POST['button_name'] != ''
208
  ? sanitize_text_field($_POST['button_name'])
250
  $form_data = array(
251
  'title' => $form_title,
252
  'description' => wpautop($form_description, true),
253
+ 'success_message' => wpautop($success_message, true),
254
  'button' => $button_name,
255
  'language' => $language,
256
  'lists' => $form_lists,
437
  'description' => __(
438
  'Just simple MailerLite form!', 'mailerlite'
439
  ),
440
+ 'success_message' => '<span style="color: rgb(51, 153, 102);">' . _e(
441
+ 'Thank you for sign up!', 'mailerlite'
442
+ ) . '</span>',
443
  'button' => __('Subscribe', 'mailerlite'),
444
  'lists' => array(),
445
  'fields' => array('email' => __('Email', 'mailerlite'))
include/templates/admin/edit_custom.php CHANGED
@@ -65,6 +65,25 @@
65
  ?>
66
  </td>
67
  </tr>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
68
  <tr>
69
  <th><label for="button_name"><?php _e('Button title', 'mailerlite'); ?></label>
70
  </th>
65
  ?>
66
  </td>
67
  </tr>
68
+ <tr>
69
+ <th><label
70
+ for="success_message"><?php _e('Success message', 'mailerlite'); ?></label>
71
+ </th>
72
+ <td>
73
+ <?php
74
+ $settings = array(
75
+ 'media_buttons' => false,
76
+ 'textarea_rows' => 4,
77
+ 'tinymce' => array(
78
+ 'toolbar1' => 'bold,italic,underline,bullist,numlist,link,unlink,forecolor,alignleft,aligncenter,alignright,undo,redo',
79
+ 'toolbar2' => ''
80
+ )
81
+ );
82
+
83
+ wp_editor(stripslashes($form->data['success_message']), 'success_message', $settings);
84
+ ?>
85
+ </td>
86
+ </tr>
87
  <tr>
88
  <th><label for="button_name"><?php _e('Button title', 'mailerlite'); ?></label>
89
  </th>
include/templates/forms/custom_form.php CHANGED
@@ -26,7 +26,11 @@
26
  <input type="hidden" name="action" value="mailerlite_subscribe_form"/>
27
  </div>
28
  <div class="mailerlite-form-response">
29
- <h4><?php _e('Thank you for signing up!', 'mailerlite'); ?></h4>
 
 
 
 
30
  </div>
31
  </form>
32
  </div>
26
  <input type="hidden" name="action" value="mailerlite_subscribe_form"/>
27
  </div>
28
  <div class="mailerlite-form-response">
29
+ <?php if (!empty($form_data['success_message'])) { ?>
30
+ <h4><?php echo $form_data['success_message'] ?></h4>
31
+ <?php } else { ?>
32
+ <h4><?php _e('Thank you for signing up!', 'mailerlite'); ?></h4>
33
+ <?php } ?>
34
  </div>
35
  </form>
36
  </div>
mailerlite.php CHANGED
@@ -4,7 +4,7 @@
4
  * Plugin Name: Official MailerLite Sign Up Forms
5
  * Description: Official MailerLite Sign Up Forms plugin for WordPress. Ability
6
  * to embed MailerLite webforms and create custom ones just with few clicks.
7
- * Version: 1.1.13
8
  * Author: MailerGroup
9
  * Author URI: https://www.mailerlite.com
10
  * License: GPLv2 or later
@@ -28,7 +28,7 @@
28
  define('MAILERLITE_PLUGIN_DIR', plugin_dir_path(__FILE__));
29
  define('MAILERLITE_PLUGIN_URL', plugins_url('', __FILE__));
30
 
31
- define('MAILERLITE_VERSION', '1.1.13');
32
 
33
  define('MAILERLITE_PHP_VERSION', '5.0.1');
34
  define('MAILERLITE_WP_VERSION', '3.0.1');
4
  * Plugin Name: Official MailerLite Sign Up Forms
5
  * Description: Official MailerLite Sign Up Forms plugin for WordPress. Ability
6
  * to embed MailerLite webforms and create custom ones just with few clicks.
7
+ * Version: 1.1.14
8
  * Author: MailerGroup
9
  * Author URI: https://www.mailerlite.com
10
  * License: GPLv2 or later
28
  define('MAILERLITE_PLUGIN_DIR', plugin_dir_path(__FILE__));
29
  define('MAILERLITE_PLUGIN_URL', plugins_url('', __FILE__));
30
 
31
+ define('MAILERLITE_VERSION', '1.1.14');
32
 
33
  define('MAILERLITE_PHP_VERSION', '5.0.1');
34
  define('MAILERLITE_WP_VERSION', '3.0.1');
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.mailerlite.com/
4
  Tags: mailerlite, newsletter, subscribe, form, webform
5
  Requires at least: 3.0.1
6
  Tested up to: 4.6
7
- Stable tag: 1.1.13
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -127,6 +127,8 @@ Add your custom CSS rules to the end of your theme stylesheet, /wp-content/theme
127
 
128
  == Changelog ==
129
 
 
 
130
  = 1.1.13 =
131
  * tested with 4.6 version
132
  = 1.1.12 =
@@ -196,6 +198,8 @@ Add your custom CSS rules to the end of your theme stylesheet, /wp-content/theme
196
 
197
  == Upgrade Notice ==
198
 
 
 
199
  = 1.1.13 =
200
  * tested with 4.6 version
201
  = 1.1.12 =
4
  Tags: mailerlite, newsletter, subscribe, form, webform
5
  Requires at least: 3.0.1
6
  Tested up to: 4.6
7
+ Stable tag: 1.1.14
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
127
 
128
  == Changelog ==
129
 
130
+ = 1.1.14 =
131
+ * custom thank you message added
132
  = 1.1.13 =
133
  * tested with 4.6 version
134
  = 1.1.12 =
198
 
199
  == Upgrade Notice ==
200
 
201
+ = 1.1.14 =
202
+ * custom thank you message added
203
  = 1.1.13 =
204
  * tested with 4.6 version
205
  = 1.1.12 =