Skip to:
Content
Pages
Categories
Search
Top
Bottom

Reply To: Profile Page visible to non-logged-in visitors

@jakobuz

Participant

Maybe you mean the buddypress profile page?
in that case this piece of code in the functions.php of your theme might help:

function sh_walled_garden()	{
	global $bp;
	if( bp_is_register_page() || bp_is_activation_page() )
	return;
	if( ! bp_is_blog_page() && ! is_user_logged_in() )
	bp_core_redirect( $bp->root_domain .'/'. 'LOGIN_PAGE_NAME' );
}
add_action( 'get_header', 'sh_walled_garden' );

‘LOGIN_PAGE_NAME’ = whatever page name you use to login

Skip to toolbar