WP_Query::next_comment() WordPress Method
The next_comment() method advances the internal comment pointer in the $wp_query object and returns the next comment in the comment list.
WP_Query::next_comment() #
Iterate current comment index and return WP_Comment object.
Return
(WP_Comment) Comment object.
Source
File: wp-includes/class-wp-query.php
public function next_comment() { $this->current_comment++; /** @var WP_Comment */ $this->comment = $this->comments[ $this->current_comment ]; return $this->comment; }
Expand full source codeCollapse full source codeView on TracView on GitHub
Changelog
Version | Description |
---|---|
2.2.0 | Introduced. |