Guten Abend laberkopp,
@robin-w
I checked your profile picture and I think I have seen you before 🙂
bbPress profiles are open by default to all, so also users that are not logged in could see your profile. I know Robin has made a quick patch for a previous version (http://www.rewweb.co.uk/bbpress-making-profile-pages-private/) but I’m not sure if it’s still valid for the current version.
Some other (untested!) snippets can be found here: http://seventhqueen.com/blog/code-snippets/restrict-guest-users-from-accessing-buddypress-or-bbpress-pages.html
Regards, Pascal.
Thanks casiepa!
I hoped for a solution without coding, but it seems I need to start digging into the fundaments of WP and bbpress.
I will go for the @robin-w solution first, as from the other one I didn’t even get where to put the code and what kleo should be.
So thanks again, I will get back here as soon as I have something to report.
Best wishes,
Sascha
You can use this php Code function instead if you are not using BuddyPress. Make sure to place it in your child themes functions.php file or in a functionality plugin.
What it does is redirect non-logged in users from see user profile pages to the default WordPress login page.
You can change the page by editing
site_url('wp-login.php');
to something like this if you have a yoursite.com/login page instead.
site_url('/login/');
function rkk_restrict_bbp_user_pages() {
if ( ! is_user_logged_in() ) {
if ( bbp_is_single_user() ) {
$url = site_url('wp-login.php');
// Send them to the new URL
wp_redirect( $url );
exit;
}
}
}
add_action( 'template_redirect', 'rkk_restrict_bbp_user_pages');
Thanks @robkk I may come back to your suggestion.
@all
I just tested the solution from @robin-w where @cassiepa pointed me to and this works very nicely for me. It is already active and seems not to influence other parts of my site. You can try if you like (link in first post 🙂
What I like on that solution, is that I just need to add two files and do not need to edit and replace an existing file.
Let’s see what will happen when I need to update the theme (if subfolder and files keep untouched, I mean).
But for now I am yery happy. This was easier than I’ve feared 🙂
Thanks a lot to all of you! I love communities 🙂
Best wishes,
Sascha
Hi,
If you are still interested, I have added it into my bbP Toolkit. It does NOT need any files to be copied or created. https://wordpress.org/plugins/bbp-toolkit/
Pascal.