[resolved] WPMU, require login to view any part of site, but allow registration (6 posts)

  1. zlamczyk
    Posted 6 years ago #

    I want a "closed" site. Only registered members may be allowed to view any part of the site. I'm currently using the Authenticate plugin to assist with this. The Authenticate program uses the following lines of code to accomplish this:

    public static function check_auth_to_read () {
    //If the current page isn't 'wp-login.php' or 'wp-register.php' redirect
    if ((strpos($_SERVER['PHP_SELF'], 'wp-login.php') === false) && (strpos($_SERVER['PHP_SELF'], 'wp-register.php') === false)) {

    My issue is that no one can register for the site. Clicking the Register link from the site redirects back to the Login page. I'm pretty sure that the problem is that WPMU does not use wp-register.php for registration.

    Could anyone tell me how to allow registration while preventing any other part of my site from being viewed? I like the idea of redirecting back to the login page.

  2. zlamczyk
    Posted 6 years ago #

    Wow, is that actually free? Suhweet!

    @andrea_r Thanks so much for the suggestion! I will test this and let you know if it does what I want!

  3. zlamczyk
    Posted 6 years ago #

    So, I set the options to "Registered Members Only" but I can still type a direct link in the address bar and for instance, view the members of the main blog.

    After logging out, I can still go here and see everything:

    Any suggestions? I haven't had much luck finding an answer on their forums.

  4. Well, those are BuddyPress areas, you didn't mention those. :)

    If you poke aroudn their forums, you'll see there's privacy options as well. Yes, for free.

  5. zlamczyk
    Posted 6 years ago #

    @andrea_r Thanks once again for your kind responses. Within just a few hours I had a great plugin suggestion from the BuddyPress forums:
    Registered Users Only 2

    I am frustrated that I somehow managed to miss that plugin in the very first place. Oh well, live and learn!

Topic Closed

This topic has been closed to new replies.

About this Topic