summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2012-12-24 13:53:38 +0400
committerAndrew Dolgov <[email protected]>2012-12-24 13:53:38 +0400
commit1b35d30c1f39c495d1ff2825ccba402bcd8a09fb (patch)
tree421a008e357af1cbd35b06d28f0b1b9f7888dba2 /include
parent19b3992b7855518c6fe05a380b6471902f5be5b7 (diff)
prevent escaping of article link in the database when using simplepie (refs #472)
Diffstat (limited to 'include')
-rw-r--r--include/rssfuncs.php15
1 files changed, 6 insertions, 9 deletions
diff --git a/include/rssfuncs.php b/include/rssfuncs.php
index da2f28a94..57413639a 100644
--- a/include/rssfuncs.php
+++ b/include/rssfuncs.php
@@ -430,7 +430,8 @@
}
$entry_title = $item->get_title();
- $entry_link = rewrite_relative_url($site_url, $item->get_link());
+
+ $entry_link = rewrite_relative_url($site_url, htmlspecialchars_decode($item->get_link()));
if ($debug_enabled) {
_debug("update_rss_feed: title $entry_title");
@@ -548,15 +549,11 @@
$article = $plugin->hook_article_filter($article);
}
- $entry_title = $article["title"];
- $entry_content = $article["content"];
$entry_tags = $article["tags"];
- $entry_author = $article["author"];
-
- $entry_content = db_escape_string($entry_content, false);
- $entry_title = db_escape_string($entry_title);
- $entry_author = db_escape_string($entry_author);
- $entry_link = db_escape_string($entry_link);
+ $entry_content = db_escape_string($article["content"], false);
+ $entry_title = db_escape_string($article["title"]);
+ $entry_author = db_escape_string($article["author"]);
+ $entry_link = db_escape_string($article["link"]);
$content_hash = "SHA1:" . sha1(strip_tags($entry_content));