Version Description
March 6 2019 = * Fix: Creating tables in DB. * Fix: PHP Warning in spam statistics widget.
Download this release
Release Info
Developer | Safronik |
Plugin | Spam protection, AntiSpam, FireWall by CleanTalk |
Version | 5.116.1 |
Comparing to | |
See all releases |
Code changes from version 5.116 to 5.116.1
- cleantalk.php +3 -3
- inc/cleantalk-updater.php +15 -1
- lib/CleantalkAPI.php +8 -10
- readme.txt +9 -1
cleantalk.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: Anti-Spam by CleanTalk
|
4 |
Plugin URI: http://cleantalk.org
|
5 |
Description: Max power, all-in-one, no Captcha, premium anti-spam plugin. No comment spam, no registration spam, no contact spam, protects any WordPress forms.
|
6 |
-
Version: 5.116
|
7 |
Author: СleanTalk <welcome@cleantalk.org>
|
8 |
Author URI: http://cleantalk.org
|
9 |
*/
|
@@ -493,7 +493,7 @@ function apbct_activation( $network ) {
|
|
493 |
|
494 |
$session_table = 'CREATE TABLE IF NOT EXISTS `%s` (
|
495 |
`id` VARCHAR(64) NOT NULL,
|
496 |
-
`name` TEXT NULL,
|
497 |
`value` TEXT NULL,
|
498 |
`last_update` DATETIME NOT NULL DEFAULT NOW(),
|
499 |
PRIMARY KEY (`id`, `name`(10)))
|
@@ -559,7 +559,7 @@ function apbct_activation__new_blog($blog_id, $user_id, $domain, $path, $site_id
|
|
559 |
|
560 |
$session__query = 'CREATE TABLE IF NOT EXISTS `%s` (
|
561 |
`id` VARCHAR(64) NOT NULL,
|
562 |
-
`name` TEXT NULL,
|
563 |
`value` TEXT NULL,
|
564 |
`last_update` DATETIME NOT NULL DEFAULT NOW(),
|
565 |
PRIMARY KEY (`id`))
|
3 |
Plugin Name: Anti-Spam by CleanTalk
|
4 |
Plugin URI: http://cleantalk.org
|
5 |
Description: Max power, all-in-one, no Captcha, premium anti-spam plugin. No comment spam, no registration spam, no contact spam, protects any WordPress forms.
|
6 |
+
Version: 5.116.1
|
7 |
Author: СleanTalk <welcome@cleantalk.org>
|
8 |
Author URI: http://cleantalk.org
|
9 |
*/
|
493 |
|
494 |
$session_table = 'CREATE TABLE IF NOT EXISTS `%s` (
|
495 |
`id` VARCHAR(64) NOT NULL,
|
496 |
+
`name` TEXT NOT NULL,
|
497 |
`value` TEXT NULL,
|
498 |
`last_update` DATETIME NOT NULL DEFAULT NOW(),
|
499 |
PRIMARY KEY (`id`, `name`(10)))
|
559 |
|
560 |
$session__query = 'CREATE TABLE IF NOT EXISTS `%s` (
|
561 |
`id` VARCHAR(64) NOT NULL,
|
562 |
+
`name` TEXT NOT NULL,
|
563 |
`value` TEXT NULL,
|
564 |
`last_update` DATETIME NOT NULL DEFAULT NOW(),
|
565 |
PRIMARY KEY (`id`))
|
inc/cleantalk-updater.php
CHANGED
@@ -170,7 +170,21 @@ function apbct_update_to_5_116_0(){
|
|
170 |
|
171 |
$wpdb->query('CREATE TABLE IF NOT EXISTS `'. APBCT_TBL_SESSIONS .'` (
|
172 |
`id` VARCHAR(64) NOT NULL,
|
173 |
-
`name` TEXT NULL,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
174 |
`value` TEXT NULL,
|
175 |
`last_update` DATETIME NOT NULL DEFAULT NOW(),
|
176 |
PRIMARY KEY (`id`, `name`(10)))
|
170 |
|
171 |
$wpdb->query('CREATE TABLE IF NOT EXISTS `'. APBCT_TBL_SESSIONS .'` (
|
172 |
`id` VARCHAR(64) NOT NULL,
|
173 |
+
`name` TEXT NOT NULL,
|
174 |
+
`value` TEXT NULL,
|
175 |
+
`last_update` DATETIME NOT NULL DEFAULT NOW(),
|
176 |
+
PRIMARY KEY (`id`, `name`(10)))
|
177 |
+
ENGINE = MYISAM;'
|
178 |
+
);
|
179 |
+
}
|
180 |
+
|
181 |
+
function apbct_update_to_5_116_1(){
|
182 |
+
|
183 |
+
global $wpdb;
|
184 |
+
|
185 |
+
$wpdb->query('CREATE TABLE IF NOT EXISTS `'. APBCT_TBL_SESSIONS .'` (
|
186 |
+
`id` VARCHAR(64) NOT NULL,
|
187 |
+
`name` TEXT NOT NULL,
|
188 |
`value` TEXT NULL,
|
189 |
`last_update` DATETIME NOT NULL DEFAULT NOW(),
|
190 |
PRIMARY KEY (`id`, `name`(10)))
|
lib/CleantalkAPI.php
CHANGED
@@ -520,7 +520,7 @@ class CleantalkAPI
|
|
520 |
// mehod_name = notice_validate_key
|
521 |
if($method_name == 'notice_validate_key' && isset($result['valid']))
|
522 |
$out = $result;
|
523 |
-
|
524 |
// Other methods
|
525 |
if(isset($result['data']) && is_array($result['data'])){
|
526 |
$out = $result['data'];
|
@@ -530,15 +530,13 @@ class CleantalkAPI
|
|
530 |
// mehod_name = get_antispam_report_breif
|
531 |
if($method_name == 'get_antispam_report_breif'){
|
532 |
|
533 |
-
|
534 |
-
$
|
535 |
-
|
536 |
-
|
537 |
-
|
538 |
-
|
539 |
-
|
540 |
-
$result['top5_spam_ip'] = isset($result['top5_spam_ip']) ? $result['top5_spam_ip'] : array();
|
541 |
-
$out = array_merge($result, $out);
|
542 |
}
|
543 |
|
544 |
return $out;
|
520 |
// mehod_name = notice_validate_key
|
521 |
if($method_name == 'notice_validate_key' && isset($result['valid']))
|
522 |
$out = $result;
|
523 |
+
|
524 |
// Other methods
|
525 |
if(isset($result['data']) && is_array($result['data'])){
|
526 |
$out = $result['data'];
|
530 |
// mehod_name = get_antispam_report_breif
|
531 |
if($method_name == 'get_antispam_report_breif'){
|
532 |
|
533 |
+
for($tmp = array(), $i = 0; $i < 7; $i++){
|
534 |
+
$tmp[date('Y-m-d', time() - 86400 * 7 + 86400 * $i)] = 0;
|
535 |
+
}
|
536 |
+
|
537 |
+
$out['spam_stat'] = (array) array_merge( $tmp, isset($out['spam_stat']) ? $out['spam_stat'] : array() );
|
538 |
+
$out['top5_spam_ip'] = isset($out['top5_spam_ip']) ? $out['top5_spam_ip'] : array();
|
539 |
+
|
|
|
|
|
540 |
}
|
541 |
|
542 |
return $out;
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: safronik
|
|
3 |
Tags: spam, antispam, protection, comments, firewall
|
4 |
Requires at least: 3.0
|
5 |
Tested up to: 5.1
|
6 |
-
Stable tag: 5.116
|
7 |
License: GPLv2
|
8 |
|
9 |
Spam protection, antispam, all-in-one, premium plugin. No spam comments & users, no spam contact form & WooCommerce anti-spam.
|
@@ -558,6 +558,10 @@ If your website has forms that send data to external sources, you can enable opt
|
|
558 |
10. Website's options.
|
559 |
|
560 |
== Changelog ==
|
|
|
|
|
|
|
|
|
561 |
= 5.116 March 6 2019 =
|
562 |
* Spam filtration quality improved.
|
563 |
* New: Storing visited URLs.
|
@@ -1808,6 +1812,10 @@ If your website has forms that send data to external sources, you can enable opt
|
|
1808 |
* First version
|
1809 |
|
1810 |
== Upgrade Notice ==
|
|
|
|
|
|
|
|
|
1811 |
= 5.116 March 6 2019 =
|
1812 |
* Spam filtration quality improved.
|
1813 |
* New: Storing visited URLs.
|
3 |
Tags: spam, antispam, protection, comments, firewall
|
4 |
Requires at least: 3.0
|
5 |
Tested up to: 5.1
|
6 |
+
Stable tag: 5.116.1
|
7 |
License: GPLv2
|
8 |
|
9 |
Spam protection, antispam, all-in-one, premium plugin. No spam comments & users, no spam contact form & WooCommerce anti-spam.
|
558 |
10. Website's options.
|
559 |
|
560 |
== Changelog ==
|
561 |
+
= 5.116.1 March 6 2019 =
|
562 |
+
* Fix: Creating tables in DB.
|
563 |
+
* Fix: PHP Warning in spam statistics widget.
|
564 |
+
|
565 |
= 5.116 March 6 2019 =
|
566 |
* Spam filtration quality improved.
|
567 |
* New: Storing visited URLs.
|
1812 |
* First version
|
1813 |
|
1814 |
== Upgrade Notice ==
|
1815 |
+
= 5.116.1 March 6 2019 =
|
1816 |
+
* Fix: Creating tables in DB.
|
1817 |
+
* Fix: PHP Warning in spam statistics widget.
|
1818 |
+
|
1819 |
= 5.116 March 6 2019 =
|
1820 |
* Spam filtration quality improved.
|
1821 |
* New: Storing visited URLs.
|