Version Description
- Modified: Check interval of follower count is tuned.
=
Download this release
Release Info
Developer | marubon |
Plugin | SNS Count Cache |
Version | 0.7.1 |
Comparing to | |
See all releases |
Code changes from version 0.7.0 to 0.7.1
- includes/admin-setting.php +6 -2
- readme.txt +5 -2
- screenshot-4.png +0 -0
- sns-count-cache.php +7 -3
includes/admin-setting.php
CHANGED
@@ -129,7 +129,11 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
|
129 |
}
|
130 |
|
131 |
if ( isset( $_POST["follow_base_check_interval"] ) && $_POST["follow_base_check_interval"] && is_numeric( $_POST["follow_base_check_interval"] ) ) {
|
132 |
-
|
|
|
|
|
|
|
|
|
133 |
}
|
134 |
|
135 |
if ( isset( $_POST["follow_base_cache_target_feedly"] ) && $_POST["follow_base_cache_target_feedly"] ) {
|
@@ -837,7 +841,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
|
837 |
<th><label><?php _e( 'Interval cheking and caching follower count (sec)', self::DOMAIN ) ?></label></th>
|
838 |
<td>
|
839 |
<input type="text" class="text" name="follow_base_check_interval" size="20" value="<?php echo esc_html( $this->follow_base_check_interval); ?>" />
|
840 |
-
|
841 |
</td>
|
842 |
</tr>
|
843 |
</table>
|
129 |
}
|
130 |
|
131 |
if ( isset( $_POST["follow_base_check_interval"] ) && $_POST["follow_base_check_interval"] && is_numeric( $_POST["follow_base_check_interval"] ) ) {
|
132 |
+
if ( $_POST["follow_base_check_interval"] >= self::OPT_FOLLOW_BASE_CHECK_INTERVAL_MIN ) {
|
133 |
+
$settings[self::DB_FOLLOW_CHECK_INTERVAL] = $_POST["follow_base_check_interval"];
|
134 |
+
} else {
|
135 |
+
$settings[self::DB_FOLLOW_CHECK_INTERVAL] = self::OPT_FOLLOW_BASE_CHECK_INTERVAL_MIN;
|
136 |
+
}
|
137 |
}
|
138 |
|
139 |
if ( isset( $_POST["follow_base_cache_target_feedly"] ) && $_POST["follow_base_cache_target_feedly"] ) {
|
841 |
<th><label><?php _e( 'Interval cheking and caching follower count (sec)', self::DOMAIN ) ?></label></th>
|
842 |
<td>
|
843 |
<input type="text" class="text" name="follow_base_check_interval" size="20" value="<?php echo esc_html( $this->follow_base_check_interval); ?>" />
|
844 |
+
<label><?php _e( 'Default: 86400 Minimum: 3600', self::DOMAIN ) ?></label>
|
845 |
</td>
|
846 |
</tr>
|
847 |
</table>
|
readme.txt
CHANGED
@@ -3,8 +3,8 @@ Contributors: marubon
|
|
3 |
Donate link:
|
4 |
Tags: performance, SNS, social, cache, share
|
5 |
Requires at least: 3.7
|
6 |
-
Tested up to: 4.2.
|
7 |
-
Stable tag: 0.7.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -112,6 +112,9 @@ There are no questions.
|
|
112 |
* Added: function to access variation of SNS count through custom filed
|
113 |
* Fixed: custom filed used in this plugin is not deleted in a certain case.
|
114 |
|
|
|
|
|
|
|
115 |
== Upgrade Notice ==
|
116 |
The following functions are deprecated.
|
117 |
|
3 |
Donate link:
|
4 |
Tags: performance, SNS, social, cache, share
|
5 |
Requires at least: 3.7
|
6 |
+
Tested up to: 4.2.3
|
7 |
+
Stable tag: 0.7.1
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
112 |
* Added: function to access variation of SNS count through custom filed
|
113 |
* Fixed: custom filed used in this plugin is not deleted in a certain case.
|
114 |
|
115 |
+
= 0.7.1 =
|
116 |
+
* Modified: Check interval of follower count is tuned.
|
117 |
+
|
118 |
== Upgrade Notice ==
|
119 |
The following functions are deprecated.
|
120 |
|
screenshot-4.png
CHANGED
Binary file
|
sns-count-cache.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
/*
|
3 |
Plugin Name: SNS Count Cache
|
4 |
Description: SNS Count Cache gets share count for Twitter and Facebook, Google Plus, Pocket, Hatena Bookmark and caches these count in the background. This plugin may help you to shorten page loading time because the share count can be retrieved not through network but through the cache using given functions.
|
5 |
-
Version: 0.7.
|
6 |
Author: Daisuke Maruyama
|
7 |
Author URI: http://marubon.info/
|
8 |
License: GPL2 or later
|
@@ -113,7 +113,8 @@ final class SNS_Count_Cache implements Order {
|
|
113 |
/**
|
114 |
* Interval cheking and caching share count for follow base cache
|
115 |
*/
|
116 |
-
const OPT_FOLLOW_BASE_CHECK_INTERVAL =
|
|
|
117 |
|
118 |
/**
|
119 |
* Interval for follow second cache
|
@@ -433,7 +434,7 @@ final class SNS_Count_Cache implements Order {
|
|
433 |
/**
|
434 |
* Plugin version, used for cache-busting of style and script file references.
|
435 |
*/
|
436 |
-
private $version = '0.7.
|
437 |
|
438 |
/**
|
439 |
* Instances of crawler
|
@@ -676,6 +677,9 @@ final class SNS_Count_Cache implements Order {
|
|
676 |
|
677 |
if ( isset( $settings[self::DB_FOLLOW_CHECK_INTERVAL] ) && $settings[self::DB_FOLLOW_CHECK_INTERVAL] ) {
|
678 |
$this->follow_base_check_interval = (int) $settings[self::DB_FOLLOW_CHECK_INTERVAL];
|
|
|
|
|
|
|
679 |
} else {
|
680 |
$this->follow_base_check_interval = self::OPT_FOLLOW_BASE_CHECK_INTERVAL;
|
681 |
}
|
2 |
/*
|
3 |
Plugin Name: SNS Count Cache
|
4 |
Description: SNS Count Cache gets share count for Twitter and Facebook, Google Plus, Pocket, Hatena Bookmark and caches these count in the background. This plugin may help you to shorten page loading time because the share count can be retrieved not through network but through the cache using given functions.
|
5 |
+
Version: 0.7.1
|
6 |
Author: Daisuke Maruyama
|
7 |
Author URI: http://marubon.info/
|
8 |
License: GPL2 or later
|
113 |
/**
|
114 |
* Interval cheking and caching share count for follow base cache
|
115 |
*/
|
116 |
+
const OPT_FOLLOW_BASE_CHECK_INTERVAL = 86400;
|
117 |
+
const OPT_FOLLOW_BASE_CHECK_INTERVAL_MIN = 3600;
|
118 |
|
119 |
/**
|
120 |
* Interval for follow second cache
|
434 |
/**
|
435 |
* Plugin version, used for cache-busting of style and script file references.
|
436 |
*/
|
437 |
+
private $version = '0.7.1';
|
438 |
|
439 |
/**
|
440 |
* Instances of crawler
|
677 |
|
678 |
if ( isset( $settings[self::DB_FOLLOW_CHECK_INTERVAL] ) && $settings[self::DB_FOLLOW_CHECK_INTERVAL] ) {
|
679 |
$this->follow_base_check_interval = (int) $settings[self::DB_FOLLOW_CHECK_INTERVAL];
|
680 |
+
if ( $this->follow_base_check_interval < self::OPT_FOLLOW_BASE_CHECK_INTERVAL_MIN ) {
|
681 |
+
$this->follow_base_check_interval = self::OPT_FOLLOW_BASE_CHECK_INTERVAL_MIN;
|
682 |
+
}
|
683 |
} else {
|
684 |
$this->follow_base_check_interval = self::OPT_FOLLOW_BASE_CHECK_INTERVAL;
|
685 |
}
|