wp_privacy_personal_data_email_to
云策文档标注
概述
wp_privacy_personal_data_email_to 是一个 WordPress 过滤器,用于修改个人数据导出邮件通知的收件人地址。开发者应谨慎使用此过滤器,以避免将数据导出链接发送到错误的邮箱。
关键要点
- 这是一个过滤器,允许开发者自定义个人数据导出邮件的收件人邮箱地址。
- 需要传入两个参数:$request_email(收件人邮箱地址)和 $request(WP_User_Request 对象)。
- 使用时应格外小心,确保邮件发送到正确的收件人,避免数据泄露风险。
代码示例
$request_email = apply_filters( 'wp_privacy_personal_data_email_to', $request->email, $request );注意事项
此过滤器从 WordPress 5.3.0 版本开始引入,主要用于隐私工具相关功能。
原文内容
Filters the recipient of the personal data export email notification.
Description
Should be used with great caution to avoid sending the data export link to the wrong email.
Parameters
$request_emailstring-
The email address of the notification recipient.
$requestWP_User_Request-
The request that is initiating the notification.
Source
$request_email = apply_filters( 'wp_privacy_personal_data_email_to', $request->email, $request );
Changelog
| Version | Description |
|---|---|
| 5.3.0 | Introduced. |