This topic has 4 replies, 3 voices, and was last updated 11 years by LKr.

  • Author
  • #6157
     LKr
    Participant

    Is it possible to make it so that when users try to register with a username that already exists, the register page when it uploads again (with a notification “This username is already taken”) does not discard the data that the user inserted into the fields. Right now, information inserted by the user into select additional fields that I included onto the registration page gets completely discarded (only email and passwords are kept in place)

    I installed a plugin to check username availability (bpdev-username-availablity), but this plugin only checks username on the main register page. If the user starts his registration process through a SignUp popup, the inserted username does not get checked by this plugin. So users get frustrated if they fill out the form and then all this information gets discarded if the username was already picked by somebody else..

    The fix would be something to keep information in these additional fields after the register page gives a notification that the Username already taken.. Or a username availability checker that would work in the popup as well.

    How did other people solve this? Any thoughts on this would be much appreciated!

    #6166
     adam
    Participant

    I agree that the register pop-up modal could really use a username availability checker 🙂 I bypass the modal though and have it set so that when someone clicks the “Sign Up” button it takes them right to the registration page instead. that way I don’t have to deal with this issue. if the username is taken, it keeps all of the user inputted information and just forces you to change the username.

    #6174
     LKr
    Participant

    Thanks Adam. One possible workaround here is to put the cursor on the username field automatically when the ../register page loads (after the popup). In this case, the plugin will check username availability (after the user moves the cursor).

    My question would then be: how to put the cursor on the username field automatically?

    #6220
     SQadmin
    Keymaster

    To put the cursor in the username fields you have to add this javascript code to registration/register.php somewhere at the end of the file before the get_footer( ‘buddypress’ ); line

    COPY CODE
    
    <script type="text/javascript">
    jQuery(document).ready( function() {
    	jQuery("#signup_username").focus();
    });
    </script>
    
    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #6255
     LKr
    Participant

    Works great – Thanks!!

Viewing 5 posts - 1 through 5 (of 5 total)

The topic ‘"Username already exists" situation at registration’ is closed to new replies.

Log in with your credentials

Forgot your details?