Uses
Uses | Description |
---|---|
wp-includes/class-wp-query.php: WP_Query::rewind_comments() | Rewind the comments, resets the comment index and comment to first. |
Whether there are more comments available.
Automatically rewinds comments when finished.
(bool) True if comments are available, false if no more comments.
File: wp-includes/class-wp-query.php
public function have_comments() { if ( $this->current_comment + 1 < $this->comment_count ) { return true; } elseif ( $this->current_comment + 1 == $this->comment_count ) { $this->rewind_comments(); } return false; }
Version | Description |
---|---|
2.2.0 | Introduced. |
© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/classes/wp_query/have_comments