Version 5.0.13

This commit is contained in:
Neo committed 2025-12-19 19:04:57 -08:00
1 parent b89858b2ff
commit 5efe744c5f
1407 files changed
+69690 -30177

No files matched your search

+23
View File
@@ -150,6 +150,7 @@ class Rss extends SimpleXML
{
$articles = array();
$items = $this->getItems();
$namespaces = $this->getDocNamespaces();
foreach ( $items as $item )
{
$link = NULL;
@@ -213,6 +214,28 @@ class Rss extends SimpleXML
$articles[ $guid ]['enclosure'] = $attr;
}
/* Loop through all child elements and just add them to the array
in case there is a custom extension to process them */
foreach( $item->children() as $name => $element )
{
if( !in_array( $name, [ 'link', 'guid', 'title', 'description', 'enclosure', 'pubDate' ] ) )
{
$articles[ $guid ][ $name ] = (string) $element;
}
}
foreach( $namespaces as $prefix => $namespace )
{
if( $prefix != 'content' and $elements = $item->children( $prefix, true ) )
{
foreach( $elements as $name => $element )
{
$articles[ $guid ][ $prefix . ':' . $name ] = (string) $element;
}
}
}
}
return $articles;
}