Make Buddypress Pages Private Unless Logged In

Usually its a good idea to make your Buddypress pages private unless the visitor is logged in. You can do just that with this small code snippet.

It starts out looking at whether or not the visitor is logged in or not, followed by which components are private. You can always delete or add to the components in the code.

Copy paste it into your bp-custom.php or functions.php file to activate it.

 

 

Leave a Reply

Your email address will not be published. Required fields are marked *