previous_posts_link()显示同分类“上一页”分页的链接

目录

描述

Prints a link to the previous set of posts within the current query.

If you need the values for use in PHP, use get_previous_posts_link().

Because post queries are usually sorted in reverse chronological order, next_posts_link() usually points to older entries (toward the end of the set) and previous_posts_link() usually points to newer entries (toward the beginning of the set).

previous_posts_link() 描述

用法

 <?php previous_posts_link$label ); ?> 

previous_posts_link() 用法

参数

$label

(string) (可选) The link text.

默认值: '« Previous Page'

previous_posts_link() 参数

示例

Default Usage

Working example

previous_posts_link() 示例

注意

  • This function does not work with static pages.

previous_posts_link() 注意

历史

添加于 版本: 0.71

previous_posts_link() 历史

源文件

previous_posts_link() 函数的代码位于 wp-includes/link-template.php.

previous_posts_link() 源文件

相关