wppaste
WordPress

apply_filters( 'comment_notification_subject', string $subject, string $comment_id )

Since
1.5.2
Filters the comment notification email subject.

Compatibility

WordPress
since 1.5.2
  • 6.7.7
  • 6.8.8
  • 6.9.7
  • 7.0.4
  • 7.1.0

Present in every tracked release (6.7.7 to 7.1.0).

Parameters

$subjectstring
The comment notification email subject.
$comment_idstring
Comment ID as a numeric string.

Where this hook fires · 1

  • wp-includes/pluggable.php:1875wp_notify_postauthor()

Source code

			 *			 * @since 1.5.2			 *			 * @param string $subject    The comment notification email subject.			 * @param string $comment_id Comment ID as a numeric string.			 */			$subject = apply_filters( 'comment_notification_subject', $subject, $comment->comment_ID ); 			wp_mail( $email, wp_specialchars_decode( $subject ), $notify_message, $message_headers ); 			if ( $switched_locale ) {				restore_previous_locale();			}

Changelog

Introduced in 1.5.2. Unchanged from 6.7.7 through 7.1.0.

  1. 6.7.7
  2. 6.8.8
  3. 6.9.7
  4. 7.0.4
  5. 7.1.0

Signature, return type and hooks compared across 5 parsed releases.

About this page

Parsed data
Generated from the wordpress-develop 6.8.8 tag, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.
Corrections
Something wrong on this page? Report it and it gets fixed in the next regeneration.