WordPress获取下一页链接函数:get_next_posts_link

WordPress函数get_next_posts_link用于在归档页获取下一页链接,在制作归档页翻页导航时非常有用。 get_next_posts_link( string $label = null, int $max_page = 0 ) 函数参数$label 字符串值,默认值:n …

WordPress获取下一篇文章信息函数:get_next_post

WordPress函数get_next_post用于获取下一篇文章的信息,包括:文章内容、摘要、状态、标题、作者、发布时间等。 get_next_post( boolean $in_same_term = false, string $excluded_terms = '', string $taxonomy = 'category' ) 函数参数$in_same_ …

WordPress获取More标签分隔内容函数:get_extended

WordPress函数get_extended用于获取More标签分隔的内容,分别输出More标签前、后、中的内容,稍加变通就可以利用这个标签制作摘要输出、加密内容等。 get_extended( string $post_content ) 函数 …

WordPress获取文章子元素函数:get_children

WordPress函数get_children可用于获取文章下的附件、子页面,通常我用来获取文章缩略图。 get_children( array $args = '', constant $output = OBJECT ) 函数参数$args数组或字符串值 get_children …

WordPress获取最早或最近文章函数:get_boundary_post

WordPress函数get_boundary_post用于获取最早或最近发表的一篇文章,在实际应用中使用得非常少。 get_boundary_post( boolean $in_same_term = false, string $excluded_terms = '', boolean $start = true, string $taxonomy = 'category' ) 函数参数$in_same_c …

WordPress获取相邻文章函数:get_adjacent_post

WordPress函数get_adjacent_post用于获取相邻文章的信息,包括文章ID、文章发表时间、文章标题、文章别名、文章内容和文章摘要等。 get_adjacent_post( boolean $in_same_term = false, array $excluded_terms = '', boolean $previous = true, string $taxonomy …

WordPress模板标签、函数中文手册

WordPress模板标签、函数汇总页面,所收集WordPress标签函数的参数说明、使用方法均已翻译为中文,并适当添加了示例。