Atom1.0 allows multiple categories for a FeedItem. I admit that I don't know if it is allowed in other formats too - but if it's allowed in other as well it would be fine if it could be added.
I'm using Joomla with the component RD_RSS which is great. I've modified it so it sends the content->metakey in the item->category array (in feedcreator.php). However, feedcreator.php doesn't split based on commas like most other RSS feeds. It just spits out the long line.
I've changed the lines in feedcreator.php to the following:
This produces a better category output in the RSS feed, which can now be used by the feed consumer to key on the categories. Some aggregators that want RSS feeds to have categories correctly want this format (like wordpress does).
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I'm using Joomla with the component RD_RSS which is great. I've modified it so it sends the content->metakey in the item->category array (in feedcreator.php). However, feedcreator.php doesn't split based on commas like most other RSS feeds. It just spits out the long line.
I've changed the lines in feedcreator.php to the following:
if ($this->items[$i]->category!="") {
$arr = split("[,]",$this->items[$i]->category);
foreach($arr as $cat) {
$feed.= " <category>\n";
$feed.= " <![CDATA[".htmlspecialchars($cat)."]]>\n";
$feed.= " </category>\n";
}
}
This produces a better category output in the RSS feed, which can now be used by the feed consumer to key on the categories. Some aggregators that want RSS feeds to have categories correctly want this format (like wordpress does).