1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.4 Make user group dependent on email verification?

Discussion in 'XenForo Questions and Support' started by jflory7, Jun 16, 2015.

  1. jflory7

    jflory7 Active Member

    Hello XenForo forums,

    For my xF installation, I have a third-party service that checks my user table to see if a particular user exists. If they do and they are in the "Registered" group, it will give them perks on this service.

    However, I don't want newly registered users being moved to the "Registered" group until after they have confirmed their email (i.e. so until then they are in the "Unregistered / Unconfirmed" group. Is this possible in vanilla XenForo? If not, is there an add-on or tweak I can do that will allow me to do this?

    - jflory7​
  2. Arty

    Arty Well-Known Member

    Its easier to update your service. When you query xf_user table for users, add user_state = 'valid' to conditions.
    AndyB likes this.
  3. Mouth

    Mouth Well-Known Member

    Yes. Just setup a user group promotion to your "Registered" group based on user state = valid.
    jflory7 and Rob like this.
  4. Martok

    Martok Well-Known Member

    In the default setup for XenForo (ie no add-ons required or 3rd party services used), as long as you have "Enable Email Confirmation" ticked in ACP > Options > User Registration then newly registered members will be in the Unregistered / Unconfirmed group until they haven't confirmed their email address via the link sent to them in the validation email.

    If this is not happening with the 3rd party service you are using (amember by any chance?) then you need to raise this with them.
  5. Mike

    Mike XenForo Developer Staff Member

    This isn't correct. Users are never put in the unregistered group. They just effectively get the permissions from it when they browse.
  6. Martok

    Martok Well-Known Member

    Sorry, I thought this was the case, particularly as the term "unconfirmed" is in the user group name. It's a little confusing that unconfirmed members get their permissions from a user group that they are not in.
  7. Rob

    Rob Well-Known Member

    As has been said, a usergroup promotion is the way to go :)
  8. jflory7

    jflory7 Active Member

    And so now the only way for any user on my forums to become "Registered" is by having a valid email address, correct? I added the promotion, but I still wonder how it will work with primary / secondary groups.
  9. Mouth

    Mouth Well-Known Member

    Not sure what it is you are wondering about?
  10. Rob

    Rob Well-Known Member

    why not just make a new usergroup called "validated users". Next, make a usergroup promotion to move users with a "valid" state to the validated users group - if you tell the promotion to change their primary group then you can point your external service to check that new group, instead of registered.
    jflory7 likes this.
  11. jflory7

    jflory7 Active Member

    I don't know why I didn't think of this – I will try this. Thanks!
    Rob likes this.

Share This Page