Wordpress 钩子:wp_count_posts
文章目录
根据当前帖子类型的状态修改返回的帖子计数。
原型
apply_filters( 'wp_count_posts', object $counts, string $type, string $perm )
参数
$counts
(object)
包含当前post_type的帖子的对象按状态计数。
$type
(string)
发布类型。
$perm
(string)
允许确定帖子是否为当前用户“可读”。
源文件
路径:wp-includes/post.php
其他
英文文档:https://developer.wordpress.org/reference/hooks/wp_count_posts/
文章作者 iBllex
上次更新 2019-02-13