Check if “Send the new user an email about their account” is ticked
I believe I found a solution. Not sure if it is the best solution but at least it serves the purpose: if ( !function_exists(‘wp_new_user_notification’) ) { function wp_new_user_notification( $user_id, $plaintext_pass=”” ) { if($_POST[‘action’] == ‘createuser’){ if($_POST[‘send_user_notification’] == 1){ $user = new WP_User($user_id); $plaintext_pass = $_POST[‘pass1’]; wp_set_password( $plaintext_pass, $user_id ); $user_login = stripslashes($user->user_login); $user_email = stripslashes($user->user_email); … Read more