4

I have Wordpress Multisite with bbPress. I've disabled new user registration from network settings but I still seem to get new registrations regardless. I've read that bbPress is most likely the cause but I don't know how to prevent the registration. I use Wanguard and bbPress moderation plugins so I am preventing them from actually posting anything but is there a way of stopping them from getting in to begin with?

1
  • That's weird. Does bbPress have its own registration settings?
    – sam
    Oct 24, 2013 at 22:56

1 Answer 1

1

This code should make it impossible to add a new user, as long as it is being added with wp_insert_user().

add_filter( 'pre_user_login', '__return_false' );

That filter is applied to the user's login name before it is saved. If the result is empty, the user isn't added. This will make it so the login will always be empty, so it will be impossible to add new users, even from the administration panels.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.