Skip to:
Content
Pages
Categories
Search
Top
Bottom

Automatically create a group when a member subscribes (based on a profile field)


  • candacekthe1
    Member

    @candacekthe1

    Hi everyone! I hope you are all experiencing the New Year to the fullest. :)

    I am working on a site for Hair Stylists and Salons. Here’s what I’ve got going on:

    WordPress 3.0.4
    BuddyPress 1.2.6

    I am using profile fields to determine a member type (stylist, salon, client).

    Is there a way to automatically create a group for the stylist or salon when they sign up?

    I assume I would have to:
    1) Check the field value to see if they are a salon or stylist.
    2) Call a create group function, assigning the member as the admin and assigning the group properties (name, etc).

    Has anyone done something similar?

    Thanks in advance!

Viewing 3 replies - 1 through 3 (of 3 total)

  • candacekthe1
    Member

    @candacekthe1

    I am assuming this is a no-go! :)


    noriise
    Participant

    @noriise

    Did you have any luck with this? I’d like to do this too…


    r-a-y
    Keymaster

    @r-a-y

    The create group function is groups_create_group(); it can be found in /bp-groups.php.

    You can add checks for profile fields when a user activates their account with the “bp_core_activated_user” action, available in the bp_core_activate_signup() function (this can be found in /bp-core/bp-core-signup.php).

    Hope that gives you a few pointers.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Automatically create a group when a member subscribes (based on a profile field)’ is closed to new replies.
Skip to toolbar