comments_template_top_level_query_args WordPress Filter Hook

This hook is used to modify the top level query arguments before they are passed to the comments template.

apply_filters( 'comments_template_top_level_query_args', array $top_level_args ) #

Filters the arguments used in the top level comments query.


Description

Top ↑

See also


Top ↑

Parameters

$top_level_args

(array)The top level query arguments for the comments template.

  • 'count'
    (bool) Whether to return a comment count.
  • 'orderby'
    (string|array) The field(s) to order by.
  • 'post_id'
    (int) The post ID.
  • 'status'
    (string|array) The comment status to limit results by.


Top ↑

Source

File: wp-includes/comment-template.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
5.6.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.

Show More
Show More