@starapple
There are two different ways to disable buddypress registration on https://gist.github.com/r-a-y/5578432
@starapple
Create a bp-custom.php if you dont have one already. For more on that see:
https://codex.buddypress.org/plugindev/bp-custom-php/
Then copy both snippets from the below link into bp-custom.php :
https://gist.github.com/r-a-y/5578432
@aces
Actually the second snippet on that page is a redirect which works well when combined with r-a-y ‘s code.
fair enough… I don’t use either…
Gentlemen, thanks for your prompt and direct replies. I will share the results soon.
No luck. With the add_filter code I get a time out on the server with this message from Chrome:
This webpage has a redirect loop
Reload Less
The webpage at http://www.site.com/wp-signup.php has resulted in too many redirects. Clearing your cookies for this site or allowing third-party cookies may fix the problem. If not, it is possibly a server configuration issue and not a problem with your computer.
Learn more about this problem.
Error code: ERR_TOO_MANY_REDIRECTS
Without the filter, I just end up with the BuddyPress registration page.
Maybe the plugin is outdated. It uses the format http://www.site.com/?reglevel=author, which, come to think of it isn’t odd because that’s the same as for logging out.
@starapple
This webpage has a redirect loop
This is likely to result from two redirects in place. 1. wp-login.php is redirecting to the BuddyPress login page. 2. The BuddyPress login page is redirecting back to the wp-login.php page.
From this, I’m assuming you’re using the firmasite_redirect_bp_signup_page
function? This would work well if (2) wasn’t happening to begin with. Then again if (2) wasn’t happening to begin with you wouldn’t have the problem.
The solution here would be to find out how BuddyPress is redirecting people away from wp-login.php and remove that redirect. I think r-a-y’s remove_action
gist is what you want. The rest of the code you’ve added I think is safe to remove.
Did that make sense? where I said “This would work well if (2) wasn’t happening to begin with. Then again if (2) wasn’t happening to begin with you wouldn’t have the problem.” – I should have actually said (1)!
@Henry, thanks for your help. When I use the firmasite_redirect_bp_signup_page
function I’m redirected to /wp-signup.php with the message about the loop. When I delete the function I’m redirected to the BuddyPress login/registration, which, on my site is /login. So yes, WP login is redirecting to the BddyPress login/registration.
I haven’t been able to disable WP redirecting to BuddyPress.
@starapple Did you try the function r-a-y wrote?
function my_disable_bp_registration() {
remove_action( 'bp_init', 'bp_core_wpsignup_redirect' );
remove_action( 'bp_screens', 'bp_core_screen_signup' );
}
add_action( 'bp_loaded', 'my_disable_bp_registration' );
You’d need to remove all the code you’ve added first then try adding that to your theme’s functions.php file.
Will do, @Henry. The other bad news (for me) is that I disabled BuddyPress and tried the RegLevel plugin and found it’s not compatible with WP 3.6.1. But I’ll still try it in functions.php as I may get lucky and find a plugin that allows role level registration.
Thanks.
That code disables the BB register redirect, but instead it redirects to the root side registration. And I have multisite, so it is a problem. Anybody knows how to make it to stay on the same subdomain?