comment_notification_subject
Filters the comment notification email subject.
Usage
add_filter( 'comment_notification_subject', 'wp_kama_comment_notification_subject_filter', 10, 2 ); /** * Function for `comment_notification_subject` filter-hook. * * @param string $subject The comment notification email subject. * @param string $comment_id Comment ID as a numeric string. * * @return string */ function wp_kama_comment_notification_subject_filter( $subject, $comment_id ){ // filter... return $subject; }
- $subject(string)
- The comment notification email subject.
- $comment_id(string)
- Comment ID as a numeric string.
Changelog
Since 1.5.2 | Introduced. |
Where the hook is called
comment_notification_subject
wp-includes/pluggable.php 1843
$subject = apply_filters( 'comment_notification_subject', $subject, $comment->comment_ID );