site_admin_email_change_email
Filters the contents of the email notification sent when the site admin email address is changed.
Usage
add_filter( 'site_admin_email_change_email', 'wp_kama_site_admin_email_change_filter', 10, 3 );
/**
* Function for `site_admin_email_change_email` filter-hook.
*
* @param array $email_change_email Used to build wp_mail().
* @param string $old_email The old site admin email address.
* @param string $new_email The new site admin email address.
*
* @return array
*/
function wp_kama_site_admin_email_change_filter( $email_change_email, $old_email, $new_email ){
// filter...
return $email_change_email;
}
- $email_change_email(array)
Used to build wp_mail().
-
to(string)
The intended recipient. -
subject(string)
The subject of the email. -
message(string)
The content of the email.The following strings have a special meaning and will get replaced dynamically: - `###OLD_EMAIL###` The old site admin email address. - `###NEW_EMAIL###` The new site admin email address. - `###SITENAME###` The name of the site. - `###SITEURL###` The URL to the site.
- headers(string)
Headers.
-
- $old_email(string)
- The old site admin email address.
- $new_email(string)
- The new site admin email address.
Changelog
| Since 4.9.0 | Introduced. |
Where the hook is called
site_admin_email_change_email
wp-includes/functions.php 8213
$email_change_email = apply_filters( 'site_admin_email_change_email', $email_change_email, $old_email, $new_email );