diff options
author | Andrew Dolgov <[email protected]> | 2013-05-23 20:32:54 +0400 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2013-05-23 20:32:54 +0400 |
commit | 1874c8d6dfd15b5517e10a29082b224d5e597216 (patch) | |
tree | da8158690560843986fd97f4f7650871252f064a /classes | |
parent | 610fe1153518a4223c2bf2d70723104932cb8d77 (diff) |
feedparser: properly handle nodeValue of rss channel link element (closes #692)
Diffstat (limited to 'classes')
-rw-r--r-- | classes/feedparser.php | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/classes/feedparser.php b/classes/feedparser.php index 6b84e59c7..a4fb348a2 100644 --- a/classes/feedparser.php +++ b/classes/feedparser.php @@ -114,8 +114,11 @@ class FeedParser { $link = $xpath->query("//channel/link")->item(0); - if ($link && $link->hasAttributes()) { - $this->link = $link->getAttribute("href"); + if ($link) { + if ($link->getAttribute("href")) + $this->link = $link->getAttribute("href"); + else if ($link->nodeValue) + $this->link = $link->nodeValue; } $articles = $xpath->query("//channel/item"); |