Version Description
Download this release
Release Info
Developer | feedsapi |
Plugin | RSS Post Importer |
Version | 2.5.2 |
Comparing to | |
See all releases |
Code changes from version 2.5.1 to 2.5.2
app/classes/admin/class-rss-pi-admin-processor.php
CHANGED
@@ -197,7 +197,7 @@ class rssPIAdminProcessor {
|
|
197 |
);
|
198 |
|
199 |
delete_option( 'rss_custom_cron_frequency' );
|
200 |
-
add_option(
|
201 |
} else {
|
202 |
$frequency = isset($_POST['frequency']) ? sanitize_text_field($_POST['frequency']) : '';
|
203 |
$custom_frequency = 'false';
|
197 |
);
|
198 |
|
199 |
delete_option( 'rss_custom_cron_frequency' );
|
200 |
+
add_option('rss_custom_cron_frequency', $rss_custom_cron_frequency);
|
201 |
} else {
|
202 |
$frequency = isset($_POST['frequency']) ? sanitize_text_field($_POST['frequency']) : '';
|
203 |
$custom_frequency = 'false';
|
app/classes/admin/class-rss-pi-admin.php
CHANGED
@@ -208,17 +208,18 @@ class rssPIAdmin {
|
|
208 |
|
209 |
// min in sec
|
210 |
$rss_min = 60;
|
211 |
-
$custom_cron_options = get_option(
|
212 |
-
if(!empty($custom_cron_options)){
|
213 |
-
|
214 |
-
|
215 |
-
|
216 |
-
|
217 |
-
|
218 |
-
|
219 |
-
|
220 |
-
|
221 |
}
|
|
|
222 |
return $schedules;
|
223 |
}
|
224 |
|
208 |
|
209 |
// min in sec
|
210 |
$rss_min = 60;
|
211 |
+
$custom_cron_options = get_option('rss_custom_cron_frequency', array());
|
212 |
+
if(! empty($custom_cron_options)) {
|
213 |
+
$rss_custom_cron = unserialize($custom_cron_options);
|
214 |
+
$rss_frequency_cron = $rss_custom_cron['frequency'];
|
215 |
+
$rss_frequency_time = $rss_custom_cron['time'];
|
216 |
+
// Adding custom cron
|
217 |
+
$schedules[$rss_frequency_cron] = array(
|
218 |
+
'interval' => $rss_min * $rss_frequency_time,
|
219 |
+
'display' => $rss_frequency_time . ' minutes'
|
220 |
+
);
|
221 |
}
|
222 |
+
|
223 |
return $schedules;
|
224 |
}
|
225 |
|
app/classes/import/class-rss-pi-cron.php
CHANGED
@@ -15,7 +15,7 @@ class rssPICron {
|
|
15 |
// hook up scheduled events
|
16 |
add_action('wp', array(&$this, 'schedule'));
|
17 |
|
18 |
-
add_action('rss_pi_cron', array(&$this, '
|
19 |
}
|
20 |
|
21 |
/**
|
@@ -31,8 +31,9 @@ class rssPICron {
|
|
31 |
|
32 |
/**
|
33 |
* Import the feeds on schedule
|
|
|
34 |
*/
|
35 |
-
function
|
36 |
|
37 |
$engine = new rssPIEngine();
|
38 |
$engine->import_feed();
|
15 |
// hook up scheduled events
|
16 |
add_action('wp', array(&$this, 'schedule'));
|
17 |
|
18 |
+
add_action('rss_pi_cron', array(&$this, 'import'));
|
19 |
}
|
20 |
|
21 |
/**
|
31 |
|
32 |
/**
|
33 |
* Import the feeds on schedule
|
34 |
+
*
|
35 |
*/
|
36 |
+
function import() {
|
37 |
|
38 |
$engine = new rssPIEngine();
|
39 |
$engine->import_feed();
|
app/classes/import/class-rss-pi-engine.php
CHANGED
@@ -183,7 +183,6 @@ class rssPIEngine {
|
|
183 |
// fetch the feed
|
184 |
$feed = fetch_feed($url);
|
185 |
|
186 |
-
|
187 |
if (is_wp_error($feed)) {
|
188 |
return false;
|
189 |
}
|
183 |
// fetch the feed
|
184 |
$feed = fetch_feed($url);
|
185 |
|
|
|
186 |
if (is_wp_error($feed)) {
|
187 |
return false;
|
188 |
}
|
app/templates/feed-table-row.php
CHANGED
@@ -116,7 +116,7 @@ if ($ajax_add || $ajax_edit):
|
|
116 |
</tr>
|
117 |
<tr>
|
118 |
<td><label for="<?php echo ($f['id']); ?>-max_posts"><?php _e("Max posts / import", 'rss-post-importer'); ?></label></td>
|
119 |
-
<td><input type="number" class="field-max_posts" name="<?php echo ($f['id']); ?>-max_posts" id="<?php echo ($f['id']); ?>-max_posts" value="<?php echo ($f['max_posts']); ?>" min="1" max="
|
120 |
</tr>
|
121 |
<tr>
|
122 |
<td>
|
116 |
</tr>
|
117 |
<tr>
|
118 |
<td><label for="<?php echo ($f['id']); ?>-max_posts"><?php _e("Max posts / import", 'rss-post-importer'); ?></label></td>
|
119 |
+
<td><input type="number" class="field-max_posts" name="<?php echo ($f['id']); ?>-max_posts" id="<?php echo ($f['id']); ?>-max_posts" value="<?php echo ($f['max_posts']); ?>" min="1" max="1000" /></td>
|
120 |
</tr>
|
121 |
<tr>
|
122 |
<td>
|
index.php
CHANGED
@@ -5,7 +5,7 @@
|
|
5 |
Plugin URI: https://wordpress.org/plugins/rss-post-importer/
|
6 |
Description: This plugin lets you set up an import posts from one or several rss-feeds and save them as posts on your site, simple and flexible.
|
7 |
Author: feedsapi
|
8 |
-
Version: 2.5.
|
9 |
Author URI: https://www.feedsapi.org/
|
10 |
License: GPLv2 or later
|
11 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
@@ -32,7 +32,7 @@ if (!defined('RSS_PI_BASENAME')) {
|
|
32 |
}
|
33 |
|
34 |
if (!defined('RSS_PI_VERSION')) {
|
35 |
-
define('RSS_PI_VERSION', '2.5.
|
36 |
}
|
37 |
|
38 |
if (!defined('RSS_PI_LOG_PATH')) {
|
5 |
Plugin URI: https://wordpress.org/plugins/rss-post-importer/
|
6 |
Description: This plugin lets you set up an import posts from one or several rss-feeds and save them as posts on your site, simple and flexible.
|
7 |
Author: feedsapi
|
8 |
+
Version: 2.5.2
|
9 |
Author URI: https://www.feedsapi.org/
|
10 |
License: GPLv2 or later
|
11 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
32 |
}
|
33 |
|
34 |
if (!defined('RSS_PI_VERSION')) {
|
35 |
+
define('RSS_PI_VERSION', '2.5.2');
|
36 |
}
|
37 |
|
38 |
if (!defined('RSS_PI_LOG_PATH')) {
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.feedsapi.org/
|
|
4 |
Tags: rss aggregation, wordpress autoblog aggregator, Autoblogger, rss autopost and syndicator, blog content curation, feedsyndicate, feedwordpress, multiple rss feed importer, rss feeds to post, content syndication, blog migration, yahoo pipes
|
5 |
Requires at least: 3.5
|
6 |
Tested up to: 4.7.4
|
7 |
-
Stable tag: 2.5.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -128,6 +128,9 @@ Learn more (and get detailed instructions) in our [contribute guide](http://jetp
|
|
128 |
|
129 |
== Change Log ==
|
130 |
|
|
|
|
|
|
|
131 |
= Version 2.5.1 =
|
132 |
* Important security update
|
133 |
|
4 |
Tags: rss aggregation, wordpress autoblog aggregator, Autoblogger, rss autopost and syndicator, blog content curation, feedsyndicate, feedwordpress, multiple rss feed importer, rss feeds to post, content syndication, blog migration, yahoo pipes
|
5 |
Requires at least: 3.5
|
6 |
Tested up to: 4.7.4
|
7 |
+
Stable tag: 2.5.2
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
128 |
|
129 |
== Change Log ==
|
130 |
|
131 |
+
= Version 2.5.2 =
|
132 |
+
* Bug fixing and improvement.
|
133 |
+
|
134 |
= Version 2.5.1 =
|
135 |
* Important security update
|
136 |
|