@mshane8
This small plugin makes all buddypress related pages private and redirects logged out visitors to the register page. Read the readme.txt and study the comments in the plugins private-community-for-bp.php if the default functionality does not meet your requirement then you can edit it to do so. Get it here:
https://github.com/bphelp/private_community_for_bp
Thanks- it is not working. I get a warning message when activated saying cannot modify header information- headers are already sent by …… theme/design.php etc….
Can this issue be resolved and how do I modify the code to only protect a single page? -members?
Sounds like your theme is throwing an error not the plugin as I have double checked that there is no whitespace. You need to check your theme for any whitespace lines before and after the opening and closing php tags and remove it. As far as modifying the plugin see line 24 in private-community-for-bp.php and change it from this:
if ( bp_is_activity_component() || bp_is_groups_component() || bp_is_group_forum() /*|| bbp_is_single_forum() || bbp_is_single_topic()*/|| bp_is_forums_component() || bp_is_blogs_component() || bp_is_page( BP_MEMBERS_SLUG ) || bp_is_profile_component() ) {
To this:
if ( || bp_is_page( BP_MEMBERS_SLUG ) ) {