comment_text WordPress Filter Hook

The comment_text hook is used to filter the text of a comment before it is displayed. This hook is called in the comments template, in the default WordPress theme.

apply_filters( 'comment_text', string $comment_text, WP_Comment|null $comment, array $args ) #

Filters the text of a comment to be displayed.


Description

Top ↑

See also


Top ↑

Parameters

$comment_text

(string)Text of the current comment.

$comment

(WP_Comment|null)The comment object. Null if not found.

$args

(array)An array of arguments.


Top ↑

Source

File: wp-includes/comment-template.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
1.2.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