- 
	
	Garrett Hyder replied to the topic [Resolved] Disable "leave group" and "request membership" buttons in the forum How-to & Troubleshooting 5 years, 5 months ago I assume you’re talking about the group listing when referring to ‘clicking the group’. In that case I believe you’d want to customize the groups/groups-loop.php template by copying it into your own theme and conditionally remove the links if the current user isn’t a member. 
 Here’s docs on the template hierarchy in Buddypress -…[Read more]
- 
	
	Garrett Hyder replied to the topic [Resolved] Disable "leave group" and "request membership" buttons in the forum How-to & Troubleshooting 5 years, 5 months ago @welshlamb10 I believe that should be possible. `
 // Remove Join/Leave Button
 function bp_remove_group_join_button( $button, $group ) {
 $current_user = wp_get_current_user();
 if ( in_array( ‘member’, (array) $current_user->roles ) ) {
 return ”;
 }
 return $button;
 }
 add_filter( ‘bp_get_group_join_button’,…[Read more]
- 
	
	Garrett Hyder replied to the topic How to get the page ID associated with a component in the forum Miscellaneous 6 years, 11 months ago Glad it’s still working. Looking at the original Trac ticket there is now a bp_core_get_directory_page_id() method for this which takes the $component as a param or defaults to bp_current_component(). Just wanted to follow-up for others looking to this as a solution… there’s now an official method which is probably more appropriate. Cheers 
	@garrett-eclipse
	Active 1 year, 11 months ago