我要投稿 | 网站地图 WordPress建站学习平台
WordPress教程网
热门标签: wordpress教程 wordpress函数 wordpress WordPress建站 wordpress插件

图文教程

当前位置:首页> 图文教程

WordPress函数the_author_posts()

发布:WordPress教程网   发布时间: 2023-02-03  游览次数:25次

介绍

the_author_posts() 显示作者已发布的文章数量,必须使用在 the_loop 中。

使用

<?php the_author_posts(); ?>

示例

显示作者名称和已经发布的文章数量。

<p><?php the_author(); ?> has blogged <?php the_author_posts(); ?> 
posts</p>

显示结果

Harriett Smith has blogged 425 posts.

参数

不接受任何传参。

本文版权归原作者所有,转载请注明原文来源出处, WordPress教程网 感谢您的支持!

本文链接: http://www.wpcn.net/829.html

WordPress教程网
WordPress教程网
相关内容