Version Description
Download this release
Release Info
Developer | feedsapi |
Plugin | RSS Post Importer |
Version | 2.3.0 |
Comparing to | |
See all releases |
Code changes from version 2.2.4 to 2.3.0
- app/classes/helpers/class-rss-pi-featured-image.php +7 -2
- index.php +3 -2
- readme.txt +5 -1
app/classes/helpers/class-rss-pi-featured-image.php
CHANGED
@@ -34,6 +34,7 @@ class rssPIFeaturedImage {
|
|
34 |
|
35 |
// get the first image from content
|
36 |
preg_match('/<img.+?src="(.+?)"[^}]+>/i', $content, $matches);
|
|
|
37 |
$img_url = (is_array($matches) && !empty($matches)) ? $matches[1] : '';
|
38 |
|
39 |
if (empty($img_url)) {
|
@@ -110,7 +111,8 @@ class rssPIFeaturedImage {
|
|
110 |
|
111 |
if (!empty($file)) {
|
112 |
// Set variables for storage, fix file filename for query strings.
|
113 |
-
preg_match('/[^\?]+\.(jpe?g|jpe|gif|png)\b/i', $file, $matches);
|
|
|
114 |
$file_array = array();
|
115 |
$file_array['name'] = basename($file);
|
116 |
|
@@ -119,7 +121,9 @@ class rssPIFeaturedImage {
|
|
119 |
|
120 |
// If error storing temporarily, return the error.
|
121 |
if (is_wp_error($file_array['tmp_name'])) {
|
122 |
-
|
|
|
|
|
123 |
}
|
124 |
|
125 |
// Do the validation and storage stuff.
|
@@ -135,4 +139,5 @@ class rssPIFeaturedImage {
|
|
135 |
return $id;
|
136 |
}
|
137 |
|
|
|
138 |
}
|
34 |
|
35 |
// get the first image from content
|
36 |
preg_match('/<img.+?src="(.+?)"[^}]+>/i', $content, $matches);
|
37 |
+
//preg_match('/< *img[^>]*src *= *["\']?([^"\']*)/i', $content, $matches);
|
38 |
$img_url = (is_array($matches) && !empty($matches)) ? $matches[1] : '';
|
39 |
|
40 |
if (empty($img_url)) {
|
111 |
|
112 |
if (!empty($file)) {
|
113 |
// Set variables for storage, fix file filename for query strings.
|
114 |
+
//preg_match('/[^\?]+\.(jpe?g|jpe|gif|png)\b/i', $file, $matches);
|
115 |
+
preg_match('/[^\?]+\.(jpg|jpe|jpeg|gif|png)/i', $file, $matches);
|
116 |
$file_array = array();
|
117 |
$file_array['name'] = basename($file);
|
118 |
|
121 |
|
122 |
// If error storing temporarily, return the error.
|
123 |
if (is_wp_error($file_array['tmp_name'])) {
|
124 |
+
@unlink($file_array['tmp_name']);
|
125 |
+
$file['tmp_name'] = '';
|
126 |
+
// return $file_array['tmp_name'];
|
127 |
}
|
128 |
|
129 |
// Do the validation and storage stuff.
|
139 |
return $id;
|
140 |
}
|
141 |
|
142 |
+
|
143 |
}
|
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.
|
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.
|
36 |
}
|
37 |
|
38 |
if (!defined('RSS_PI_LOG_PATH')) {
|
@@ -40,6 +40,7 @@ if (!defined('RSS_PI_LOG_PATH')) {
|
|
40 |
}
|
41 |
|
42 |
if (!is_dir(RSS_PI_LOG_PATH)) {
|
|
|
43 |
mkdir(RSS_PI_LOG_PATH);
|
44 |
}
|
45 |
|
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.3.0
|
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.3.0');
|
36 |
}
|
37 |
|
38 |
if (!defined('RSS_PI_LOG_PATH')) {
|
40 |
}
|
41 |
|
42 |
if (!is_dir(RSS_PI_LOG_PATH)) {
|
43 |
+
//if (!file_exists(RSS_PI_LOG_PATH)){
|
44 |
mkdir(RSS_PI_LOG_PATH);
|
45 |
}
|
46 |
|
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.2.4
|
7 |
-
Stable tag:
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -128,6 +128,10 @@ Learn more (and get detailed instructions) in our [contribute guide](http://jetp
|
|
128 |
|
129 |
== Change Log ==
|
130 |
|
|
|
|
|
|
|
|
|
131 |
= Version 2.2.4 =
|
132 |
* German Encoding Bug fix
|
133 |
* Bug fixing
|
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.2.4
|
7 |
+
Stable tag: 2.3.0
|
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.3.0 =
|
132 |
+
* Featured Image Fix
|
133 |
+
* Logs Fix
|
134 |
+
|
135 |
= Version 2.2.4 =
|
136 |
* German Encoding Bug fix
|
137 |
* Bug fixing
|