In this tutorial, I will explain how to remove group tab from the user profile in BuddyPress. This is a simple and easy BuddyPress snippet which will remove the Group tabs from user’s profile page.
Open the functions.php file and add the following snippet at the end of the file.
1 2 3 4 5 6 | //Remove groups tab from profile function bphelp_remove_groups_from_profile(){ bp_core_remove_nav_item('groups'); } add_action('bp_groups_setup_nav','bphelp_remove_groups_from_profile'); |
After adding the above code the Group tabs will be removed, see the below screenshot.
If you like FreeWebMentor and you would like to contribute, you can write an article and mail your article to [email protected] Your article will appear on the FreeWebMentor main page and help other developers.
Article Tags: buddypress profile plugin, buddypress snippets, buddypress tutorial, buddypress tutorial 2018, buddypress tutorial beginners, buddypress tutorials