Skip to:
Content
Pages
Categories
Search
Top
Bottom

Update user roles with mysql query.

  • @jbboy

    Participant

    Hi!

    I’m searching for a bbproles field in the wordpress/bbpress database but with no luck. In wich table and row are they stored? What I want to do is create a form who change the user role if an “update user role code” facilitated by forum admin is correct.

    Thank you very much in advance for your replies. 🙂

Viewing 4 replies - 1 through 4 (of 4 total)
  • @tharsheblows

    Participant

    If it were me, I’d start by looking through here:
    http://www.sourcexref.com/xref/bbpress/nav.html?includes/users/capabilities.php.source.html

    and probably try using bbp_set_user_role (starting on line 58) to change the role.

    But I haven’t done it, so that who knows if that would work!

    @jbboy

    Participant

    Thank you tharsheblows, so if I want to update the actual logged in user role I must use bbp_profile_update_role() function?

    @jbboy

    Participant

    Can’t figure it out, here’s te portion of code that It’s not working:

    $_POST[‘bbp-forums-role’] = “keymaster”;
    bbp_profile_update_role();

    For example, I only want to update actual bbpress logged in user role with “keymaster” role.

    Maybe I’m not using bbp_profile_update_role() in the right way. 🙁

    @tharsheblows

    Participant

    Sorry, I’m not really sure. But good luck with it!

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.
Skip to toolbar