On this page
apply_filters( 'comment_text', string $comment_text, WP_Comment|null $comment, array $args )
Filters the text of a comment to be displayed.
Description
See also
Parameters
$comment_textstring-
Text of the current comment.
$commentWP_Comment|null-
The comment object. Null if not found.
$argsarray-
An array of arguments.
Source
File: wp-includes/comment-template.php. View all references
echo apply_filters( 'comment_text', $comment_text, $comment, $args );
Related
Used By
| Used By | Description |
|---|---|
| WP_REST_Comments_Controller::prepare_item_for_response() wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php | Prepares a single comment output for response. |
| comment_text() wp-includes/comment-template.php | Displays the text of the current comment. |
| check_comment() wp-includes/comment.php | Checks whether a comment passes internal checks to be allowed to add. |
Changelog
| Version | Description |
|---|---|
| 1.2.0 | Introduced. |
© 2003–2022 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/hooks/comment_text