If you want users to register with the same email account, you can use this filter:
function sumun_remove_registration_errors ($errors, $sanitized_user_login, $user_email) { if( isset($errors->errors['email_exists'])) { $errors->remove('email_exists'); } return $errors; } add_filter( 'registration_errors', 'sumun_remove_registration_errors', 10, 3);
Note that “remove” function is available since WordPress 4.1.0. If you are using a prior version you should use:
unset( $errors->errors['email_exists'] ); unset( $errors->error_data['email_exists'] );
instead.
But we were working on a Buddypress site and this solution does not work in BP signup form, so we had to search another solution. Here it is:
function sumun_remove_bp_email_exists_error($result) { $result['errors']->remove('user_email'); } add_filter('bp_core_validate_user_signup','sumun_remove_bp_email_exists_error');
Use it at your own risk, because it generates an inconsistence in password reset. I made a workaround installing Allow multiple accounts plugin, which appends some text to emails sent to users with usernames associated to this email account.
Cheers