WPDev.one
Core Function
View Source on Trac ↗

get_pending_comments_num()

get_pending_comments_num( mixed $post_id )

Gets the number of pending comments on a post or posts.

Parameters 1 required

Name / Type Description
(int

| int[]) $post_id Either a single Post ID or an array of Post IDs

Required

Return Value

((int)
| int[]) Either a single Posts pending comments as an int or an array of ints keyed on the Post IDs

Function Information

Since Version
2.3.0
Source File
wp-admin/includes/comment.php
Advertisement