Official MailerLite Sign Up Forms - Version 1.1.12

Version Description

  • multisite support
Download this release

Release Info

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

Code changes from version 1.1.10 to 1.1.12

include/mailerlite-admin.php CHANGED
@@ -154,10 +154,12 @@ class MailerLite_Admin
154
  && $_GET['view'] == 'edit'
155
  && absint($_GET['id'])
156
  ) {
 
 
157
  $form_id = absint($_GET['id']);
158
 
159
  $form = $wpdb->get_row(
160
- "SELECT * FROM " . $wpdb->prefix
161
  . "mailerlite_forms WHERE id = " . $form_id
162
  );
163
 
@@ -250,7 +252,7 @@ class MailerLite_Admin
250
  );
251
 
252
  $wpdb->update(
253
- $wpdb->prefix . 'mailerlite_forms',
254
  array(
255
  'name' => $form_name,
256
  'data' => serialize($form_data)
@@ -298,7 +300,7 @@ class MailerLite_Admin
298
  );
299
 
300
  $wpdb->update(
301
- $wpdb->prefix . 'mailerlite_forms',
302
  array(
303
  'name' => $form_name,
304
  'data' => serialize($form_data)
@@ -318,7 +320,7 @@ class MailerLite_Admin
318
  }
319
  } else {
320
  $forms_data = $wpdb->get_results(
321
- "SELECT * FROM " . $wpdb->prefix
322
  . "mailerlite_forms ORDER BY time DESC"
323
  );
324
 
@@ -331,13 +333,13 @@ class MailerLite_Admin
331
  && absint($_GET['id'])
332
  ) {
333
  $wpdb->delete(
334
- $wpdb->prefix . 'mailerlite_forms', array('id' => $_GET['id'])
335
  );
336
  wp_redirect('admin.php?page=mailerlite_main');
337
  } //Signup forms list
338
  else {
339
  $forms_data = $wpdb->get_results(
340
- "SELECT * FROM " . $wpdb->prefix
341
  . "mailerlite_forms ORDER BY time DESC"
342
  );
343
 
@@ -442,7 +444,7 @@ class MailerLite_Admin
442
  }
443
 
444
  $wpdb->insert(
445
- $wpdb->prefix . 'mailerlite_forms',
446
  array(
447
  'name' => $form_name,
448
  'time' => date('Y-m-d h:i:s'),
154
  && $_GET['view'] == 'edit'
155
  && absint($_GET['id'])
156
  ) {
157
+ $_POST = array_map( 'stripslashes_deep', $_POST);
158
+
159
  $form_id = absint($_GET['id']);
160
 
161
  $form = $wpdb->get_row(
162
+ "SELECT * FROM " . $wpdb->base_prefix
163
  . "mailerlite_forms WHERE id = " . $form_id
164
  );
165
 
252
  );
253
 
254
  $wpdb->update(
255
+ $wpdb->base_prefix . 'mailerlite_forms',
256
  array(
257
  'name' => $form_name,
258
  'data' => serialize($form_data)
300
  );
301
 
302
  $wpdb->update(
303
+ $wpdb->base_prefix . 'mailerlite_forms',
304
  array(
305
  'name' => $form_name,
306
  'data' => serialize($form_data)
320
  }
321
  } else {
322
  $forms_data = $wpdb->get_results(
323
+ "SELECT * FROM " . $wpdb->base_prefix
324
  . "mailerlite_forms ORDER BY time DESC"
325
  );
326
 
333
  && absint($_GET['id'])
334
  ) {
335
  $wpdb->delete(
336
+ $wpdb->base_prefix . 'mailerlite_forms', array('id' => $_GET['id'])
337
  );
338
  wp_redirect('admin.php?page=mailerlite_main');
339
  } //Signup forms list
340
  else {
341
  $forms_data = $wpdb->get_results(
342
+ "SELECT * FROM " . $wpdb->base_prefix
343
  . "mailerlite_forms ORDER BY time DESC"
344
  );
345
 
444
  }
445
 
446
  $wpdb->insert(
447
+ $wpdb->base_prefix . 'mailerlite_forms',
448
  array(
449
  'name' => $form_name,
450
  'time' => date('Y-m-d h:i:s'),
include/mailerlite-form.php CHANGED
@@ -59,7 +59,7 @@ class MailerLite_Form
59
 
60
  if ($form_id > 0 && isset($form_fields['email'])) {
61
  $form = $wpdb->get_row(
62
- "SELECT * FROM " . $wpdb->prefix
63
  . "mailerlite_forms WHERE id = " . $form_id
64
  );
65
 
@@ -199,7 +199,7 @@ function load_mailerlite_form($form_id)
199
  global $wpdb;
200
 
201
  $form = $wpdb->get_row(
202
- "SELECT * FROM " . $wpdb->prefix . "mailerlite_forms WHERE id = "
203
  . $form_id
204
  );
205
 
59
 
60
  if ($form_id > 0 && isset($form_fields['email'])) {
61
  $form = $wpdb->get_row(
62
+ "SELECT * FROM " . $wpdb->base_prefix
63
  . "mailerlite_forms WHERE id = " . $form_id
64
  );
65
 
199
  global $wpdb;
200
 
201
  $form = $wpdb->get_row(
202
+ "SELECT * FROM " . $wpdb->base_prefix . "mailerlite_forms WHERE id = "
203
  . $form_id
204
  );
205
 
include/mailerlite-shortcode.php CHANGED
@@ -77,7 +77,7 @@ class MailerLite_Shortcode
77
  }
78
 
79
  $forms = $wpdb->get_results(
80
- "SELECT * FROM " . $wpdb->prefix . "mailerlite_forms"
81
  );
82
 
83
  include(MAILERLITE_PLUGIN_DIR
77
  }
78
 
79
  $forms = $wpdb->get_results(
80
+ "SELECT * FROM " . $wpdb->base_prefix . "mailerlite_forms"
81
  );
82
 
83
  include(MAILERLITE_PLUGIN_DIR
include/mailerlite-widget.php CHANGED
@@ -36,7 +36,7 @@ class MailerLite_Widget extends WP_Widget
36
  $instance['mailerlite_form_id']
37
  ) ? $instance['mailerlite_form_id'] : 0;
38
  $form = $wpdb->get_row(
39
- "SELECT * FROM " . $wpdb->prefix . "mailerlite_forms WHERE id = "
40
  . $form_id
41
  );
42
 
@@ -68,7 +68,7 @@ class MailerLite_Widget extends WP_Widget
68
  global $wpdb;
69
 
70
  $forms_data = $wpdb->get_results(
71
- "SELECT * FROM " . $wpdb->prefix
72
  . "mailerlite_forms ORDER BY time DESC"
73
  );
74
 
36
  $instance['mailerlite_form_id']
37
  ) ? $instance['mailerlite_form_id'] : 0;
38
  $form = $wpdb->get_row(
39
+ "SELECT * FROM " . $wpdb->base_prefix . "mailerlite_forms WHERE id = "
40
  . $form_id
41
  );
42
 
68
  global $wpdb;
69
 
70
  $forms_data = $wpdb->get_results(
71
+ "SELECT * FROM " . $wpdb->base_prefix
72
  . "mailerlite_forms ORDER BY time DESC"
73
  );
74
 
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.10
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.10');
32
 
33
  define('MAILERLITE_PHP_VERSION', '5.0.1');
34
  define('MAILERLITE_WP_VERSION', '3.0.1');
@@ -73,7 +73,7 @@ function mailerlite_install()
73
  wp_die($message, 'Plugin Activation Error', array('response' => 200, 'back_link' => TRUE));
74
  }
75
 
76
- $table_name = $wpdb->prefix . "mailerlite_forms";
77
 
78
  //$charset_collate = $wpdb->get_charset_collate();
79
 
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.12
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.12');
32
 
33
  define('MAILERLITE_PHP_VERSION', '5.0.1');
34
  define('MAILERLITE_WP_VERSION', '3.0.1');
73
  wp_die($message, 'Plugin Activation Error', array('response' => 200, 'back_link' => TRUE));
74
  }
75
 
76
+ $table_name = $wpdb->base_prefix . "mailerlite_forms";
77
 
78
  //$charset_collate = $wpdb->get_charset_collate();
79
 
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.5.1
7
- Stable tag: 1.1.10
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -127,6 +127,10 @@ Add your custom CSS rules to the end of your theme stylesheet, /wp-content/theme
127
 
128
  == Changelog ==
129
 
 
 
 
 
130
  = 1.1.10 =
131
  * mistype - signing up
132
  = 1.1.9 =
@@ -190,6 +194,10 @@ Add your custom CSS rules to the end of your theme stylesheet, /wp-content/theme
190
 
191
  == Upgrade Notice ==
192
 
 
 
 
 
193
  = 1.1.10 =
194
  * mistype - signing up
195
  = 1.1.9 =
4
  Tags: mailerlite, newsletter, subscribe, form, webform
5
  Requires at least: 3.0.1
6
  Tested up to: 4.5.1
7
+ Stable tag: 1.1.12
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.12 =
131
+ * multisite support
132
+ = 1.1.11 =
133
+ * post escaped with stripslashes_deep
134
  = 1.1.10 =
135
  * mistype - signing up
136
  = 1.1.9 =
194
 
195
  == Upgrade Notice ==
196
 
197
+ = 1.1.12 =
198
+ * multisite support
199
+ = 1.1.11 =
200
+ * post escaped with stripslashes_deep
201
  = 1.1.10 =
202
  * mistype - signing up
203
  = 1.1.9 =