user_erasure_fulfillment_email_headers
Filter HookDescription
Filters the headers of the data erasure fulfillment notification. to the value of `$request->email`, but can be changed by the `user_erasure_fulfillment_email_to` filter. }Hook Information
File Location |
wp-includes/user.php
View on GitHub
|
Hook Type | Filter |
Line Number | 4633 |
Hook Parameters
Type | Name | Description |
---|---|---|
string|array
|
$headers
|
The email headers. |
string
|
$subject
|
The email subject. |
string
|
$content
|
The email content. |
int
|
$request_id
|
The request ID. |
array
|
$email_data
|
{ Data relating to the account action email. |
Usage Examples
Basic Usage
<?php
// Hook into user_erasure_fulfillment_email_headers
add_filter('user_erasure_fulfillment_email_headers', 'my_custom_filter', 10, 5);
function my_custom_filter($headers, $subject, $content, $request_id, $email_data) {
// Your custom filtering logic here
return $headers;
}
Source Code Context
wp-includes/user.php:4633
- How this hook is used in WordPress core
<?php
4628 * @type string $privacy_policy_url Privacy policy URL.
4629 * @type string $sitename The site name sending the mail.
4630 * @type string $siteurl The site URL sending the mail.
4631 * }
4632 */
4633 $headers = apply_filters( 'user_erasure_fulfillment_email_headers', $headers, $subject, $content, $request_id, $email_data );
4634
4635 $email_sent = wp_mail( $user_email, $subject, $content, $headers );
4636
4637 if ( $switched_locale ) {
4638 restore_previous_locale();
PHP Documentation
<?php
/**
* Filters the headers of the data erasure fulfillment notification.
*
* @since 5.8.0
*
* @param string|array $headers The email headers.
* @param string $subject The email subject.
* @param string $content The email content.
* @param int $request_id The request ID.
* @param array $email_data {
* Data relating to the account action email.
*
* @type WP_User_Request $request User request object.
* @type string $message_recipient The address that the email will be sent to. Defaults
* to the value of `$request->email`, but can be changed
* by the `user_erasure_fulfillment_email_to` filter.
* @type string $privacy_policy_url Privacy policy URL.
* @type string $sitename The site name sending the mail.
* @type string $siteurl The site URL sending the mail.
* }
*/
Quick Info
- Hook Type: Filter
- Parameters: 5
- File: wp-includes/user.php
Related Hooks
Related hooks will be displayed here in future updates.