像这样使用。
add_filter( \'password_change_email\', \'wpse207879_change_password_mail_message\', 10, 3 );
function wpse207879_change_password_mail_message( $pass_change_mail, $user, $userdata ) {
$new_message_txt = __( \'Some text ###USERNAME### more text
even more text ###EMAIL### more text after more text
last bit of text ###SITENAME###\' );
$pass_change_mail[ \'message\' ] = $new_message_txt;
return $pass_change_mail;
}
上述代码的参考号为:
Change Password notification text on mail此筛选器位于wp_update_user()
功能和isdocumented here.