Notifications
Clear all

wpForo 1.x.x [Closed] Removal of Options in "Show Menu Bar" for certain User Groups

3 Posts
2 Users
0 Reactions
1,676 Views
Cotty
Posts: 23
Topic starter
(@cotty)
Eminent Member
Joined: 8 years ago

As the title states, is there a way of removing certain options within the menu bar?

For example as in the image attached?

We're looking at reducing the options for registered users and want a clean setup (we're using another plugin for profiles / logout)?

Kindest Regards

Cotty

2 Replies
Sofy
Posts: 4900
 Sofy
Admin
(@sofy)
Support Team
Joined: 7 years ago

Hi Cotty,

I'm sorry, but there is no any option for this purpose.  You need to use the code like this one (put the code in current active theme functions.php file):

function mycustom_wpforo_menu_array_filter($menu){
if( WPF()->current_user_groupid == 8 ){
unset( $menu['wpforo-profile-account'] );
}
unset( $menu['wpforo-logout'] );
return $menu;
}
add_filter('wpforo_menu_array_filter', 'mycustom_wpforo_menu_array_filter');
Cotty
Posts: 23
Topic starter
(@cotty)
Eminent Member
Joined: 8 years ago

Thanks for the reply Sofy, its very much appreciated!

Hopefully, you'll consider adding this customisation feature at some point. 

Thanks Again