Filter
rpress_user_registration_email_username
On this page
Filters the username line of the welcome email.
Runs in rpress_new_user_notification() and sets the start of the email message. The default is 'Username: ' followed by the login name and a line break.
Parameters#
| Parameter | Type | Description |
|---|---|---|
$username_line | string | Username line text, ending with a line break. |
$user_data | array | User data array for the new account, including user_login and user_email. |
Return value#
string. Text that begins the welcome email message.
Example#
function my_welcome_username_line( $username_line, $user_data ) {
return sprintf( 'Your login: %s', $user_data['user_login'] ) . "\r\n";
}
add_filter( 'rpress_user_registration_email_username', 'my_welcome_username_line', 10, 2 );
Source#
Applied in:
includes/user-functions.php(line 524), inrpress_new_user_notification()
See also#
Was this page helpful?
