Created
May 21, 2016 13:43
-
-
Save moafzalmulla/9f427c6603f37b22ec6cf040757dc194 to your computer and use it in GitHub Desktop.
Add this to functions.php then the person will be able to reg with email as username
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// register with email | |
function custom_register_with_email($result) { | |
if ( $result['user_name'] != '' && is_email( $result['user_name'] ) ) { | |
unset( $result['errors']->errors['user_name'] ); | |
} | |
return $result; | |
} | |
add_filter('wpmu_validate_user_signup','custom_register_with_email'); | |
// Hide labels | |
add_filter( 'gform_enable_field_label_visibility_settings', '__return_true' ); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment