admin管理员组文章数量:1418352
This is most likely a duplicate and I'm just struggling for the right way to search it but what file is used to display actual pages of posts, not the post type of page but like /blog/page/2/ for the second page of most recent posts?
Searching reveals only how to make a template that applies to a page, but what if I just want it to apply to pagination?
The function I use to generate a link to this template is previous_posts_link();
This is most likely a duplicate and I'm just struggling for the right way to search it but what file is used to display actual pages of posts, not the post type of page but like /blog/page/2/ for the second page of most recent posts?
Searching reveals only how to make a template that applies to a page, but what if I just want it to apply to pagination?
The function I use to generate a link to this template is previous_posts_link();
1 Answer
Reset to default 1It’s the same template used for displaying the normal page (example, page.php) but you have a conditional tag is_paged
https://codex.wordpress/Function_Reference/is_paged
which can help you to achieve whatever you want for the other pages /2/, /3/, etc.
本文标签: theme developmentWhat template file is used for homepage pagination
版权声明:本文标题:theme development - What template file is used for homepage pagination? 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1745288820a2651666.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论