WordPress:Template Tags/single post title
来自站长百科
描述[ ]
当在一个只有一篇文章的网页上时(permalink 网页),显示或者返回文章标题。对于在The Loop外显示文章标题,这个标签非常有用。
用法[ ]
%%% <?php single_post_title('prefix', display); ?> %%%
例子[ ]
<h2><?php single_post_title('Current post: '); ?></h2>
当前文章:单一的文章的标题
参数[ ]
- prefix
- (string) 标题之前放置的文本。默认为''。
- display
- (boolean) 标题应该显示(TRUE)还是返回用在PHP中(FALSE)。默认为TRUE。
相关的[ ]
the_ID, the_title, the_title_attribute, single_post_title, the_title_rss, the_content, the_content_rss, the_excerpt, the_excerpt_rss, previous_post_link, next_post_link, posts_nav_link, the_meta,