Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: All site data visible to members and non-members alike


Windhamdavid
Participant

@windhamdavid

<?php if(!is_user_logged_in()){

nocache_headers();

header("HTTP/1.1 302 Moved Temporarily");

header('Location: ' . get_settings('siteurl') . '/wp-signup.php?redirect_to=' . urlencode($_SERVER['REQUEST_URI']));

header("Status: 302 Moved Temporarily");

exit();

} ?>

this quick hack (in the top of header.php) will only registered and logged in users can view. As for using it with version 1.2 default theme ~ I would suggest making a custom header for any of the buddypress elements you want to keep private and keep the rest public. At least until privacy functions are available as a plugin or in core.

Skip to toolbar