Set user ID to be the row ID in the users table

Support MB Frontend Submission Set user ID to be the row ID in the users tableResolved

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #33207
    Nicholas CoxNicholas Cox
    Participant

    Hi

    Every time a user is registered I would like to set their username to be the row ID set in the user table (users).

    I would like to do this as I have no reason for users to use the username field on my website as they need to sign in with their email address. So rather than having a random int assigned to them i thought it would make sense to use the row id.

    Any help would be great thanks! I just wanted to choose the best approach.

    #33221
    Long NguyenLong Nguyen
    Moderator

    Hi,

    You can follow this topic to know how to change the username (user_login) by coding.
    https://stackoverflow.com/questions/46972779/unable-to-update-an-username-in-wordpress

    #33233
    Nicholas CoxNicholas Cox
    Participant

    ok thanks!

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.