WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] First Name set to username (How to avoid this?) (6 posts)

  1. Nyhm
    Member
    Posted 3 years ago #

    My site registration does not collect first/last name. However, WordPress insists upon filling the First Name field with the username. This is not appropriate in my case (and causes some other side-effects).

    1. Can I tell WordPress not to apply the username to the First Name field? (I want it left blank.)
    2. Or, can I remove the First Name field entirely (and others that I don't need)?

    Many thanks for any advice.

  2. Samuel Wood (Otto)
    Tech Ninja
    Posted 3 years ago #

    Registering a new user does not set the first name field to anything, actually.

    How are you registering this user?

  3. Nyhm
    Member
    Posted 3 years ago #

    @Otto, thanks for the quick reply. Interesting... maybe it's not a WordPress behavior, but rather a plugin causing this side-effect.

    Here's what happens: User registers by providing username, email, and password. (Not first name, last name, Jabber, website, etc.) Upon inspecting the user's profile, their First Name field is set to their username (but I want First Name to remain empty).

    If this is, indeed, not a WordPress behavior, then I'm barking up the wrong tree. Can anyone confirm this (I don't have a good test environment in which to tinker right now).

  4. Samuel Wood (Otto)
    Tech Ninja
    Posted 3 years ago #

    The normal WP registration process only asks for username and email. Not a password. The generated password gets emailed to the user.

    And I've confirmed, first name is not set in that process.

  5. Nyhm
    Member
    Posted 3 years ago #

    My thanks. I will look deeper into this issue to figure out what is setting my First Name field.

  6. Nyhm
    Member
    Posted 3 years ago #

    I've got it cornered. I'm using s2Member plugin, which takes over part of the user registration process. When no First Name is collected, it populates the First Name field with the username.

    The fine folks at s2Member are (preliminarily) considering this to be a legacy bug (apparently WordPress required First Name to be populated upon registration at some time in the past).

    The problem I was encountering was the the excellent Register Plus Redux plugin sets a bogus random string into the username upon registration to prevent login until a verification link is followed (via email). Upon verification, the username is set to that chosen by the user. However, the ugly random string was sticking forever in the First Name field, which other components mistakenly could take as a valid First Name.

    The problem should be resolved when s2Member patches this issue. Thanks WordPress community (i.e., Otto) for helping me isolate the cause of this issue.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.