apply_filters( 'found_comments_query', string $found_comments_query, WP_Comment_Query $comment_query )
- Since
- 4.4.0
Filters the query used to retrieve found comment count.
Parameters
$found_comments_querystring- SQL query. Default 'SELECT FOUND_ROWS()'.
$comment_queryWP_Comment_Query- The
WP_Comment_Queryinstance.
Fired at · 1
wp-includes/class-wp-comment-query.php:1013WP_Comment_Query::set_found_comments()
Source
* * @since 4.4.0 * * @param string $found_comments_query SQL query. Default 'SELECT FOUND_ROWS()'. * @param WP_Comment_Query $comment_query The `WP_Comment_Query` instance. */ $found_comments_query = apply_filters( 'found_comments_query', 'SELECT FOUND_ROWS()', $this ); $this->found_comments = (int) $wpdb->get_var( $found_comments_query ); } } /**History
Introduced in 4.4.0. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.
About this page
- Parsed data
- Generated from the wordpress-develop 6.8.8 tag, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.
- Corrections
- Something wrong on this page? Report it and it gets fixed in the next regeneration.