Version Description
It is highly recommended that you upgrade to WP Live Chat Support version 8.0.11 if using PHP 5.3 or below.
Download this release
Release Info
Developer | WP-LiveChat |
Plugin | WP Live Chat Support |
Version | 8.0.11 |
Comparing to | |
See all releases |
Code changes from version 8.0.10 to 8.0.11
- modules/gdpr.php +34 -34
- readme.txt +7 -1
- wp-live-chat-support.php +5 -2
modules/gdpr.php
CHANGED
@@ -23,18 +23,18 @@ add_action("wplc_hook_privacy_options_content", "wplc_gdpr_settings_content", 10
|
|
23 |
* Adds the GDPR sepcific settings to the Privacy tab
|
24 |
*/
|
25 |
function wplc_gdpr_settings_content($wplc_settings = false){
|
26 |
-
|
27 |
|
28 |
-
|
29 |
-
|
30 |
<tbody>
|
31 |
<tr>
|
32 |
<td width="250" valign="top">
|
33 |
<label for="wplc_gdpr_enabled"><?php _e("Enbled GDPR Compliance", "wplivechat"); ?> <i class="fa fa-question-circle wplc_light_grey wplc_settings_tooltip" title="<?php _e('Disabling will disable all GDPR related options, this is not advised.', 'wplivechat'); ?>"></i></label>
|
34 |
</td>
|
35 |
<td>
|
36 |
-
|
37 |
-
|
38 |
</td>
|
39 |
</tr>
|
40 |
|
@@ -43,7 +43,7 @@ function wplc_gdpr_settings_content($wplc_settings = false){
|
|
43 |
<label for="wplc_gdpr_notice_company"><?php _e("Company Name", "wplivechat"); ?></label>
|
44 |
</td>
|
45 |
<td>
|
46 |
-
|
47 |
</td>
|
48 |
</tr>
|
49 |
|
@@ -52,7 +52,7 @@ function wplc_gdpr_settings_content($wplc_settings = false){
|
|
52 |
<label for="wplc_gdpr_notice_retention_purpose"><?php _e("Retention Purpose", "wplivechat"); ?></label>
|
53 |
</td>
|
54 |
<td>
|
55 |
-
|
56 |
</td>
|
57 |
</tr>
|
58 |
|
@@ -61,7 +61,7 @@ function wplc_gdpr_settings_content($wplc_settings = false){
|
|
61 |
<label for="wplc_gdpr_notice_retention_period"><?php _e("Retention Period", "wplivechat"); ?></label>
|
62 |
</td>
|
63 |
<td>
|
64 |
-
|
65 |
</td>
|
66 |
</tr>
|
67 |
|
@@ -81,26 +81,26 @@ function wplc_gdpr_settings_content($wplc_settings = false){
|
|
81 |
</tr>
|
82 |
|
83 |
<tr>
|
84 |
-
|
85 |
<label><?php _e("GDPR Notice", "wplivechat"); ?>
|
86 |
-
|
87 |
</label>
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
echo "<br><br>";
|
94 |
-
echo apply_filters('wplc_gdpr_create_opt_in_checkbox_filter', "");
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
</tr>
|
99 |
|
100 |
|
101 |
</tbody>
|
102 |
</table>
|
103 |
-
|
104 |
}
|
105 |
|
106 |
add_filter("wplc_settings_save_filter_hook", "wplc_gdpr_settings_save_hooked", 10, 1);
|
@@ -131,10 +131,10 @@ add_action("wplc_hook_menu", "wplc_gdpr_add_menu");
|
|
131 |
* Adds a menu specifically dedicated to GDPR
|
132 |
*/
|
133 |
function wplc_gdpr_add_menu(){
|
134 |
-
|
135 |
|
136 |
-
|
137 |
-
|
138 |
}
|
139 |
}
|
140 |
|
@@ -142,8 +142,8 @@ function wplc_gdpr_add_menu(){
|
|
142 |
* Handles the layout for the GDPR page
|
143 |
*/
|
144 |
function wplc_gdpr_page_layout(){
|
145 |
-
|
146 |
-
|
147 |
|
148 |
<small><em><?php _e("Search is performed on chat sessions, messages, and offline messages. Data will also be deleted automatically per your retention policy.", "wplivechat"); ?></em></small>
|
149 |
<?php do_action('wplc_gdpr_page_before_table_hook'); ?>
|
@@ -185,15 +185,15 @@ function wplc_gdpr_page_layout(){
|
|
185 |
/**Setup Defaults*/
|
186 |
$cid_identidier = 'id';
|
187 |
$action_action_filter = 'chat_session';
|
188 |
-
$show_fields =
|
189 |
switch ($original_heading) {
|
190 |
case 'chat_messages':
|
191 |
$cid_identidier = 'chat_sess_id';
|
192 |
-
$show_fields =
|
193 |
break;
|
194 |
case 'offline_messages':
|
195 |
$action_action_filter = 'offline_message';
|
196 |
-
$show_fields =
|
197 |
break;
|
198 |
}
|
199 |
|
@@ -237,7 +237,7 @@ function wplc_gdpr_page_layout(){
|
|
237 |
|
238 |
<?php do_action('wplc_gdpr_page_after_table_hook'); ?>
|
239 |
|
240 |
-
|
241 |
}
|
242 |
|
243 |
add_action('admin_init', 'wplc_gdpr_admin_init', 1);
|
@@ -337,7 +337,7 @@ function wplc_gdpr_return_chat_session_search_results($term){
|
|
337 |
$results_message = $wpdb->get_results("SELECT * FROM $wplc_tblname_msgs WHERE `msg` LIKE '%$term%'", ARRAY_A);
|
338 |
$results_offline = $wpdb->get_results("SELECT * FROM $wplc_tblname_offline_msgs WHERE `name` LIKE '%$term%' OR `email` LIKE '%$term%' OR `message` LIKE '%$term%'", ARRAY_A);
|
339 |
|
340 |
-
$formatted_messages =
|
341 |
foreach ($results_message as $key => $value) {
|
342 |
$cid = isset($value['chat_sess_id']) ? $value['chat_sess_id'] : false;
|
343 |
if($cid !== false){
|
@@ -352,11 +352,11 @@ function wplc_gdpr_return_chat_session_search_results($term){
|
|
352 |
}
|
353 |
}
|
354 |
|
355 |
-
$return_results =
|
356 |
'chat_sessions' => $results_chats,
|
357 |
'chat_messages' => $formatted_messages,
|
358 |
'offline_messages' => $results_offline
|
359 |
-
|
360 |
|
361 |
return $return_results;
|
362 |
|
@@ -366,9 +366,9 @@ function wplc_gdpr_return_chat_session_search_results($term){
|
|
366 |
* Generates a localized retention notice message
|
367 |
*/
|
368 |
function wplc_gdpr_generate_retention_agreement_notice($wplc_settings = false){
|
369 |
-
|
370 |
|
371 |
-
|
372 |
$company_replacement = isset($wplc_settings['wplc_gdpr_notice_company']) ? $wplc_settings['wplc_gdpr_notice_company'] : get_bloginfo('name');
|
373 |
$purpose_replacement = isset($wplc_settings['wplc_gdpr_notice_retention_purpose']) ? $wplc_settings['wplc_gdpr_notice_retention_purpose'] : __('Chat/Support', 'wplivechat');
|
374 |
$period_replacement = isset($wplc_settings['wplc_gdpr_notice_retention_period']) ? intval($wplc_settings['wplc_gdpr_notice_retention_period']) : 30;
|
23 |
* Adds the GDPR sepcific settings to the Privacy tab
|
24 |
*/
|
25 |
function wplc_gdpr_settings_content($wplc_settings = false){
|
26 |
+
if($wplc_settings === false){ $wplc_settings = get_option("WPLC_SETTINGS"); }
|
27 |
|
28 |
+
?>
|
29 |
+
<table class="wp-list-table wplc_list_table widefat fixed striped pages">
|
30 |
<tbody>
|
31 |
<tr>
|
32 |
<td width="250" valign="top">
|
33 |
<label for="wplc_gdpr_enabled"><?php _e("Enbled GDPR Compliance", "wplivechat"); ?> <i class="fa fa-question-circle wplc_light_grey wplc_settings_tooltip" title="<?php _e('Disabling will disable all GDPR related options, this is not advised.', 'wplivechat'); ?>"></i></label>
|
34 |
</td>
|
35 |
<td>
|
36 |
+
<input type="checkbox" name="wplc_gdpr_enabled" value="1" <?php echo(isset($wplc_settings['wplc_gdpr_enabled']) && $wplc_settings['wplc_gdpr_enabled'] == '1' ? 'checked' : ''); ?> >
|
37 |
+
<a href="https://www.eugdpr.org/" target="_blank"><?php _e("Importance of GDPR Compliance", "wplivechat"); ?></a>
|
38 |
</td>
|
39 |
</tr>
|
40 |
|
43 |
<label for="wplc_gdpr_notice_company"><?php _e("Company Name", "wplivechat"); ?></label>
|
44 |
</td>
|
45 |
<td>
|
46 |
+
<input type="text" name="wplc_gdpr_notice_company" value="<?php echo(isset($wplc_settings['wplc_gdpr_notice_company']) ? $wplc_settings['wplc_gdpr_notice_company'] : get_bloginfo('name')); ?>" >
|
47 |
</td>
|
48 |
</tr>
|
49 |
|
52 |
<label for="wplc_gdpr_notice_retention_purpose"><?php _e("Retention Purpose", "wplivechat"); ?></label>
|
53 |
</td>
|
54 |
<td>
|
55 |
+
<input type="text" name="wplc_gdpr_notice_retention_purpose" value="<?php echo(isset($wplc_settings['wplc_gdpr_notice_retention_purpose']) ? $wplc_settings['wplc_gdpr_notice_retention_purpose'] : __('Chat/Support', 'wplivechat')); ?>" >
|
56 |
</td>
|
57 |
</tr>
|
58 |
|
61 |
<label for="wplc_gdpr_notice_retention_period"><?php _e("Retention Period", "wplivechat"); ?></label>
|
62 |
</td>
|
63 |
<td>
|
64 |
+
<input type="number" name="wplc_gdpr_notice_retention_period" value="<?php echo(isset($wplc_settings['wplc_gdpr_notice_retention_period']) ? intval($wplc_settings['wplc_gdpr_notice_retention_period']) < 1 ? 1 : intval($wplc_settings['wplc_gdpr_notice_retention_period']) : 30); ?>" > <?php _e('days', 'wplivechat'); ?>
|
65 |
</td>
|
66 |
</tr>
|
67 |
|
81 |
</tr>
|
82 |
|
83 |
<tr>
|
84 |
+
<td width="250" valign="top">
|
85 |
<label><?php _e("GDPR Notice", "wplivechat"); ?>
|
86 |
+
<i class="fa fa-question-circle wplc_light_grey wplc_settings_tooltip" title="<?php _e('Users will be asked to accept the notice shown here, in the form of a check box.', 'wplivechat'); ?>"></i>
|
87 |
</label>
|
88 |
+
</td>
|
89 |
+
<td>
|
90 |
+
<span>
|
91 |
+
<?php
|
92 |
+
echo wplc_gdpr_generate_retention_agreement_notice($wplc_settings);
|
93 |
echo "<br><br>";
|
94 |
+
echo apply_filters('wplc_gdpr_create_opt_in_checkbox_filter', "");
|
95 |
+
?>
|
96 |
+
</span>
|
97 |
+
</td>
|
98 |
</tr>
|
99 |
|
100 |
|
101 |
</tbody>
|
102 |
</table>
|
103 |
+
<?php
|
104 |
}
|
105 |
|
106 |
add_filter("wplc_settings_save_filter_hook", "wplc_gdpr_settings_save_hooked", 10, 1);
|
131 |
* Adds a menu specifically dedicated to GDPR
|
132 |
*/
|
133 |
function wplc_gdpr_add_menu(){
|
134 |
+
$wplc_settings = get_option("WPLC_SETTINGS");
|
135 |
|
136 |
+
if(isset($wplc_settings['wplc_gdpr_enabled']) && $wplc_settings['wplc_gdpr_enabled'] == '1'){
|
137 |
+
add_submenu_page('wplivechat-menu', __('GDPR', 'wplivechat'), __('GDPR', 'wplivechat'), 'manage_options', 'wplivechat-menu-gdpr-page', 'wplc_gdpr_page_layout');
|
138 |
}
|
139 |
}
|
140 |
|
142 |
* Handles the layout for the GDPR page
|
143 |
*/
|
144 |
function wplc_gdpr_page_layout(){
|
145 |
+
?>
|
146 |
+
<h2><?php _e('WP Live Chat Support - GDPR', 'wplivechat'); ?></h2>
|
147 |
|
148 |
<small><em><?php _e("Search is performed on chat sessions, messages, and offline messages. Data will also be deleted automatically per your retention policy.", "wplivechat"); ?></em></small>
|
149 |
<?php do_action('wplc_gdpr_page_before_table_hook'); ?>
|
185 |
/**Setup Defaults*/
|
186 |
$cid_identidier = 'id';
|
187 |
$action_action_filter = 'chat_session';
|
188 |
+
$show_fields = array('name', 'email');
|
189 |
switch ($original_heading) {
|
190 |
case 'chat_messages':
|
191 |
$cid_identidier = 'chat_sess_id';
|
192 |
+
$show_fields = array('msg');
|
193 |
break;
|
194 |
case 'offline_messages':
|
195 |
$action_action_filter = 'offline_message';
|
196 |
+
$show_fields = array('name', 'email', 'message');
|
197 |
break;
|
198 |
}
|
199 |
|
237 |
|
238 |
<?php do_action('wplc_gdpr_page_after_table_hook'); ?>
|
239 |
|
240 |
+
<?php
|
241 |
}
|
242 |
|
243 |
add_action('admin_init', 'wplc_gdpr_admin_init', 1);
|
337 |
$results_message = $wpdb->get_results("SELECT * FROM $wplc_tblname_msgs WHERE `msg` LIKE '%$term%'", ARRAY_A);
|
338 |
$results_offline = $wpdb->get_results("SELECT * FROM $wplc_tblname_offline_msgs WHERE `name` LIKE '%$term%' OR `email` LIKE '%$term%' OR `message` LIKE '%$term%'", ARRAY_A);
|
339 |
|
340 |
+
$formatted_messages = array();
|
341 |
foreach ($results_message as $key => $value) {
|
342 |
$cid = isset($value['chat_sess_id']) ? $value['chat_sess_id'] : false;
|
343 |
if($cid !== false){
|
352 |
}
|
353 |
}
|
354 |
|
355 |
+
$return_results = array(
|
356 |
'chat_sessions' => $results_chats,
|
357 |
'chat_messages' => $formatted_messages,
|
358 |
'offline_messages' => $results_offline
|
359 |
+
);
|
360 |
|
361 |
return $return_results;
|
362 |
|
366 |
* Generates a localized retention notice message
|
367 |
*/
|
368 |
function wplc_gdpr_generate_retention_agreement_notice($wplc_settings = false){
|
369 |
+
if($wplc_settings === false){ $wplc_settings = get_option("WPLC_SETTINGS"); }
|
370 |
|
371 |
+
$localized_notice = __("I agree for my personal data to be processed and for the use of cookies in order to engage in a chat processed by %%COMPANY%%, for the purpose of %%PURPOSE%%, for the time of %%PERIOD%% day(s) as per the GDPR.", "wplivechat");
|
372 |
$company_replacement = isset($wplc_settings['wplc_gdpr_notice_company']) ? $wplc_settings['wplc_gdpr_notice_company'] : get_bloginfo('name');
|
373 |
$purpose_replacement = isset($wplc_settings['wplc_gdpr_notice_retention_purpose']) ? $wplc_settings['wplc_gdpr_notice_retention_purpose'] : __('Chat/Support', 'wplivechat');
|
374 |
$period_replacement = isset($wplc_settings['wplc_gdpr_notice_retention_period']) ? intval($wplc_settings['wplc_gdpr_notice_retention_period']) : 30;
|
readme.txt
CHANGED
@@ -208,6 +208,9 @@ If the live chat box still does not appear on your website, please go through th
|
|
208 |
|
209 |
== Upgrade Notice ==
|
210 |
|
|
|
|
|
|
|
211 |
= 8.0.09 =
|
212 |
It is highly recommended that you upgrade to WP Live Chat Support version 8.0.09 for GDPR compliance.
|
213 |
|
@@ -232,7 +235,10 @@ We have patched the PHPMailer vulnerability. Please update to version 7.0.02.
|
|
232 |
|
233 |
== Changelog ==
|
234 |
|
235 |
-
= 8.0.
|
|
|
|
|
|
|
236 |
* Resyncs files for GDPR modules to load correctly
|
237 |
|
238 |
= 8.0.09 - 2018-05-25 - High priority =
|
208 |
|
209 |
== Upgrade Notice ==
|
210 |
|
211 |
+
= 8.0.11 =
|
212 |
+
It is highly recommended that you upgrade to WP Live Chat Support version 8.0.11 if using PHP 5.3 or below.
|
213 |
+
|
214 |
= 8.0.09 =
|
215 |
It is highly recommended that you upgrade to WP Live Chat Support version 8.0.09 for GDPR compliance.
|
216 |
|
235 |
|
236 |
== Changelog ==
|
237 |
|
238 |
+
= 8.0.11 - 2018-05-28 - High priority =
|
239 |
+
* Fixed a bug that caused a fatal error on PHP 5.3 and below
|
240 |
+
|
241 |
+
= 8.0.10 - 2018-05-25 - Medium priority =
|
242 |
* Resyncs files for GDPR modules to load correctly
|
243 |
|
244 |
= 8.0.09 - 2018-05-25 - High priority =
|
wp-live-chat-support.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: WP Live Chat Support
|
4 |
Plugin URI: http://www.wp-livechat.com
|
5 |
Description: The easiest to use website live chat plugin. Let your visitors chat with you and increase sales conversion rates with WP Live Chat Support.
|
6 |
-
Version: 8.0.
|
7 |
Author: WP-LiveChat
|
8 |
Author URI: http://www.wp-livechat.com
|
9 |
Text Domain: wplivechat
|
@@ -11,6 +11,9 @@
|
|
11 |
*/
|
12 |
|
13 |
/**
|
|
|
|
|
|
|
14 |
* 8.0.10 - Medium priority
|
15 |
* Resyncs files for GDPR modules to load correctly
|
16 |
*
|
@@ -632,7 +635,7 @@ global $debug_start;
|
|
632 |
$wplc_tblname_offline_msgs = $wpdb->prefix . "wplc_offline_messages";
|
633 |
$wplc_tblname_chats = $wpdb->prefix . "wplc_chat_sessions";
|
634 |
$wplc_tblname_msgs = $wpdb->prefix . "wplc_chat_msgs";
|
635 |
-
$wplc_version = "8.0.
|
636 |
|
637 |
define('WPLC_BASIC_PLUGIN_DIR', dirname(__FILE__));
|
638 |
define('WPLC_BASIC_PLUGIN_URL', plugins_url( '/', __FILE__ ) );
|
3 |
Plugin Name: WP Live Chat Support
|
4 |
Plugin URI: http://www.wp-livechat.com
|
5 |
Description: The easiest to use website live chat plugin. Let your visitors chat with you and increase sales conversion rates with WP Live Chat Support.
|
6 |
+
Version: 8.0.11
|
7 |
Author: WP-LiveChat
|
8 |
Author URI: http://www.wp-livechat.com
|
9 |
Text Domain: wplivechat
|
11 |
*/
|
12 |
|
13 |
/**
|
14 |
+
* 8.0.11 - High priority
|
15 |
+
* Fixed a bug that caused a fatal error on PHP 5.3 and below
|
16 |
+
*
|
17 |
* 8.0.10 - Medium priority
|
18 |
* Resyncs files for GDPR modules to load correctly
|
19 |
*
|
635 |
$wplc_tblname_offline_msgs = $wpdb->prefix . "wplc_offline_messages";
|
636 |
$wplc_tblname_chats = $wpdb->prefix . "wplc_chat_sessions";
|
637 |
$wplc_tblname_msgs = $wpdb->prefix . "wplc_chat_msgs";
|
638 |
+
$wplc_version = "8.0.11";
|
639 |
|
640 |
define('WPLC_BASIC_PLUGIN_DIR', dirname(__FILE__));
|
641 |
define('WPLC_BASIC_PLUGIN_URL', plugins_url( '/', __FILE__ ) );
|