[Resolved] BP Multi Network (need some advice, please.)

  • Participant
    Level: Initiated
    Posts: 15
    RickHN on #22220

    ¡Hi Brajesh!

    Many Thanks, the function you sent me, it seems is working very well!!

    I just have this doubt…

    What happens with user role if the register form allow to choose other role than “suscriber”? Is replaced by ‘suscriber’ as the code you sent me are defined in function or its just ignored?

    And a last question… How can assign more than one role in ‘add_user_to_blog()’ function?

    I’m a really grateful with your help and this great service for us the “simple mortals” 🙂 trying in what you are a Hero!

    Have a great day..!


  • Keymaster
    (BuddyDev Team)
    Posts: 24308
    Brajesh Singh on #22226

    Hi Rick,
    Thank you for the kind words and confirming that the code works.

    Since role can be passed as the parameter in add_user_to_blog(), it is doable when the need comes.

    I do not use the specific plugin for registration, so you can show my code to the author of the plugin and they can update it with the actual role from their form(It should be 1 line change).

    I used subscriber as a safe bate, the right thing would have been to use get_option(‘default_role’) which picks the default role for current blog.

    We do not need to worry about multiple roles, they should work as expected.


You must be logged in to reply to this topic.

This topic is: resolved