WordPress开发者和主题制作者的搜索引擎



get_category_feed_link ›

Since2.5.0
已弃用n/a
get_category_feed_link ( $cat_id, $feed = '' )
参数: (2)
  • (int) $cat_id Category ID.
    Required: Yes
  • (string) $feed Optional. Feed type. Possible values include 'rss2', 'atom'. Default is the value of get_default_feed().
    Required: No
    默认: (empty)
返回:
  • (string) Link to the feed for the category specified by $cat_id.
定义在:
文档:

Retrieves the feed link for a category.

Returns a link to the feed for all posts in a given category. A specific feed can be requested or left blank to get the default feed.



源码

function get_category_feed_link( $cat_id, $feed = '' ) {
	return get_term_feed_link( $cat_id, 'category', $feed );
}