BuddyDev

Search

is cher any function do change the level membership by coding?

  • Participant
    Level: Initiated
    Posts: 1
    CATTA on #34452

    I did not test this function

    
    // Set the member type of user 5412 to 'student'.
    $member_type = bp_set_member_type( 5412, 'student' );

    Di I need to install your plugin so as to create another membership level. ?
    Can I custom the code to change the membership level recently added with that function?

    Will it work?
    Many thanks

  • Keymaster
    (BuddyDev Team)
    Posts: 21810
    Brajesh Singh on #34453

    Hi,
    Welcome to BuddyDev.

    1. You do not nede our plugin to create member types. You can do it via code(and in BuddyPress 7.0+ you can do it from dashboard).
    Here is a link to code
    https://buddydev.com/using-buddypress-member-types-api-like-a-pro-introduction/

    2. Yes, you can.

    Regards
    Brajesh

  • Participant
    Level: Initiated
    Posts: 1
    CATTA on #34458

    thank you

  • Keymaster
    (BuddyDev Team)
    Posts: 21810
    Brajesh Singh on #34459

    You are welcome.

You must be logged in to reply to this topic.

This topic is: not resolved