wpmu_signup_blog_notification_subject
云策文档标注
概述
wpmu_signup_blog_notification_subject 是一个 WordPress 过滤器钩子,用于修改新博客通知邮件的主题。它允许开发者自定义邮件主题的文本内容。
关键要点
- 这是一个过滤器钩子,用于过滤新博客通知邮件的主题字符串。
- 接受多个参数,包括站点域名、路径、标题、用户登录名、用户邮箱、激活密钥和元数据。
- 默认主题基于 _x() 函数生成,包含网络标题和新站点 URL 的占位符。
代码示例
apply_filters(
'wpmu_signup_blog_notification_subject',
_x( '[%1$s] Activate %2$s', 'New site notification email subject' ),
$domain,
$path,
$title,
$user_login,
$user_email,
$key,
$meta
)注意事项
- 此钩子与 wpmu_signup_blog_notification() 函数关联,用于发送新站点确认邮件。
- 在 WordPress MU 3.0.0 版本中引入,适用于多站点网络环境。
原文内容
Filters the subject of the new blog notification email.
Parameters
$subjectstring-
Subject of the notification email.
$domainstring-
Site domain.
$pathstring-
Site path.
$titlestring-
Site title.
$user_loginstring-
User login name.
$user_emailstring-
User email address.
$keystring-
Activation key created in wpmu_signup_blog() .
$metaarray-
Signup meta data. By default, contains the requested privacy setting and lang_id.
Source
apply_filters(
'wpmu_signup_blog_notification_subject',
/* translators: New site notification email subject. 1: Network title, 2: New site URL. */
_x( '[%1$s] Activate %2$s', 'New site notification email subject' ),
$domain,
$path,
$title,
$user_login,
$user_email,
$key,
$meta
),
Changelog
| Version | Description |
|---|---|
| MU (3.0.0) | Introduced. |