Replies
- Brajesh Singh on June 21, 2021 at 11:23 pm in reply to: [Resolved] Add roles to users on new registration and first login #39211
HiTosin,
you code is good except this lineget_user_by('id', $user_id)->set_role('active member');I do not think role ids can have space. If you are using a plugin to create the role, Please use the role id and not the label. For example, “subscriber” is the role while “Subscriber” is the role label.
Here is an example containing your code(modified).
/** * Change user role on first login */ function buddydev_change_user_role_on_first_login( $user_login, $user ) { if ( ! function_exists( 'buddypress' ) || user_can( $user->ID, 'manage_options' ) ) { return; } // check for user's last activity. $last_activity = bp_get_user_last_activity( $user->ID ); if ( empty( $last_activity ) ) { $role = 'subscriber'; // please change with your desired role. $user->set_role( $role ); } } add_action( 'wp_login', 'buddydev_change_user_role_on_first_login', - 1, 2 );Regards
Brajesh - Brajesh Singh on June 19, 2021 at 10:23 pm in reply to: Buddy Circle add icon not displaying in member list #39200
Hi Troy,
Please upgrade to 1.1.7. It supports the button in BuddyBoss theme’s members directory.Regards
Brajesh - Brajesh Singh on June 19, 2021 at 3:14 pm in reply to: [Resolved] BuddyPress Profile Visibility Manager #39197
Hi,
I hope you have it solved now.
Marking it resolved due to lack of replies.Regards
Brajesh - Brajesh Singh on June 19, 2021 at 3:13 pm in reply to: [Resolved] Add roles to users on new registration and first login #39196
Hi Tosin,
1. You can set default role from Dashboard->settings->General screen and then updating the “New User Default Role” option.
2. You do have the code for first login action, you can do a get_user_by(‘id’, $user_id)->set_role(‘Your custom role id’) to set this new role.
e.g get_user_by(‘id’, $user_id)->set_role(‘subscriber’)
Hope that helps.
Regards
Brajesh - Brajesh Singh on June 19, 2021 at 2:55 pm in reply to: [Resolved] Showing message to user after their profile is complete #39195
Marking resolved due to lack of reply.
- Brajesh Singh on June 19, 2021 at 2:54 pm in reply to: [Resolved] Reposition custom profile action button #39194
I am marking it resolved due to lack of reply. Please feel free to open a new topic and reference it in future.
Regards
Brajesh - Brajesh Singh on June 19, 2021 at 2:49 pm in reply to: [Resolved] “Group Type” Filter for BuddyPress Group Tabs Creator Pro #39193
Thank you Nick. I am glad you found it 🙂
Regards
Brajesh - Brajesh Singh on June 19, 2021 at 2:49 pm in reply to: [Resolved] How a user can unblock a blocked user #39192
Hi Daniel,
Please visit Your profile->Settings-> Blocked.You can remove a user from the block list here.
Regards
Brajesh - Brajesh Singh on June 19, 2021 at 2:46 pm in reply to: How to add shortcode to a Parent tab rather than subnav? #39191
Hi Nick,
Thank you for the question.It was not possible earlier when we create this plugin. It is feasible now. I have tested and both BuddyPress and BuddyBoss support this now.
We will release an update in next couple of days to have this option.
Regards
Brajesh - Brajesh Singh on June 19, 2021 at 1:15 pm in reply to: [Buddyblog Pro] Custom post type and comments don’t appear in activity stream #39190
Hi Hugo,
The activity recording for custom post type is working fine for me.Please have a look.
https://i.imgur.com/ollai4x.pngI have set
'public' => true,in the post type registration code.
Regards
Brajesh