mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-13 19:05:55 +00:00
add support for dc:subject and slash:comments
This commit is contained in:
@@ -63,9 +63,12 @@ class FeedItem_RSS {
|
||||
|
||||
}
|
||||
|
||||
// todo
|
||||
function get_comments_count() {
|
||||
$comments = $this->xpath->query("slash:comments", $this->elem)->item(0);
|
||||
|
||||
if ($comments) {
|
||||
return $comments->nodeValue;
|
||||
}
|
||||
}
|
||||
|
||||
function get_categories() {
|
||||
@@ -76,6 +79,12 @@ class FeedItem_RSS {
|
||||
array_push($cats, $cat->nodeValue);
|
||||
}
|
||||
|
||||
$categories = $this->xpath->query("dc:subject", $this->elem);
|
||||
|
||||
foreach ($categories as $cat) {
|
||||
array_push($cats, $cat->nodeValue);
|
||||
}
|
||||
|
||||
return $cats;
|
||||
}
|
||||
|
||||
@@ -96,8 +105,6 @@ class FeedItem_RSS {
|
||||
|
||||
$enclosures = $this->xpath->query("media:content", $this->elem);
|
||||
|
||||
$encs = array();
|
||||
|
||||
foreach ($enclosures as $enclosure) {
|
||||
$enc = new FeedEnclosure();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user