WordPress: Template Tags/the category rss:修订间差异
来自站长百科
无编辑摘要 |
无编辑摘要 |
||
第1行: | 第1行: | ||
== 描述 == | == 描述 == | ||
在[[WordPress:Glossary#RSS|RSS]]格式中,显示类别名称或者一篇文章所属的类别的名称。必须在[[WordPress:The Loop]]内部使用这个标签。 | 在[[WordPress:Glossary#RSS|RSS]]格式中,显示类别名称或者一篇文章所属的类别的名称。必须在[[WordPress:The Loop]]内部使用这个标签。 | ||
== 用法== | == 用法== | ||
第11行: | 第6行: | ||
%%% <?php the_category_rss('type') ?> %%% | %%% <?php the_category_rss('type') ?> %%% | ||
== 例子 == | == 例子 == | ||
一个RSS2 feed网页的部分。 | 一个RSS2 feed网页的部分。 | ||
<?php the_category_rss() ?> | <?php the_category_rss() ?> | ||
<guid><?php the_permalink($id); ?></guid> | <guid><?php the_permalink($id); ?></guid> | ||
== 参数== | == 参数== | ||
; 类型 : (''string'') 显示的feed的类型。有效的参数值: | ; 类型 : (''string'') 显示的feed的类型。有效的参数值: | ||
:*<tt>'rss'</tt> (默认) | :*<tt>'rss'</tt> (默认) | ||
:*<tt>'rdf'</tt> | :*<tt>'rdf'</tt> | ||
== 相关的 == | == 相关的 == | ||
{{标签 类别标签}} | {{标签 类别标签}} | ||
{{PHP函数标签页底文字}} | {{PHP函数标签页底文字}} |
2008年7月5日 (六) 17:13的最新版本
描述[ ]
在RSS格式中,显示类别名称或者一篇文章所属的类别的名称。必须在WordPress:The Loop内部使用这个标签。
用法[ ]
%%% <?php the_category_rss('type') ?> %%%
例子[ ]
一个RSS2 feed网页的部分。 <?php the_category_rss() ?>
<guid><?php the_permalink($id); ?></guid>
参数[ ]
- 类型
- (string) 显示的feed的类型。有效的参数值:
- 'rss' (默认)
- 'rdf'
相关的[ ]
the_category, the_category_rss, single_cat_title, category_description, wp_dropdown_categories, wp_list_categories, in_category, get_category_parents, get_the_category get_category_link