Membership 2: Registration is currently not allowed.

People are not longer able to register accounts using Membership 2 on my Multisite network. It used to work but now it's not working. I've checked Network Settings to ensure the "Logged in users may register new sites." setting is selected...so that means people should be able to register right? But when they click the button for the Membership subscription to purchase it, it displays: "Registration is currently not allowed."

See for yourself: http://techsitebuilder.com/register/

I have already enabled support access if you want to jump in.

I look forward to a prompt reply.

  • Kasia Swiderska
    • Support nomad

    Hi packjazz,

    It's working right now - you need to have enabled "Both sites and user accounts can be registered." option. Previously you only allowed users that are in WordPress create sites - but you didn't allow new ones to register on your site.
    In Membership 2 pro - user first need to register to the site.

    Kind regards,
    Kasia

  • packjazz
    • The Incredible Code Injector

    @Kasia,

    Thanks, but I need it to be on "Logged in users may register new sites." I can't have random visitors be able to sign up for a site, they need to first pay for a user account (through Membership 2) before they can register a site. This was working just a couple days ago, and since then the only thing that's really changed is that one of your support people logged into the site to troubleshoot another issue.

    I need visitors to be able to register for an account through Membership 2, but NOT be able to register a site until AFTER they become a user.

  • packjazz
    • The Incredible Code Injector

    Hey guys, I really need to get this figured out. My website and membership service was supposed to relaunch earlier this week, but this has prevented me from doing so. I absolutely need to get this resolved by Sunday. Is there a way I can schedule a time to work with one of your support staff to figure this out?

  • Philipp Stracker
    • The Crimson Coder

    Hi packjazz,

    the current behaviour that you describe actually is the intended logic - that it was working in earlier versions was a bug.
    M2 - by default - uses the Registration-Settings from WordPress to decide if users are allowed to register or not. So if WordPress does not allow registration, M2 does not allow it either.

    You can customize this default behavior by using the filter "ms_member_can_register" we provide in the M2 plugin. Save this code to a new php file in /wp-content/plugins/ (e.g. m2-registration.php)
    Then you will see a new plugin called "M2 Open Registration" in your plugins list - enable the plugin and guests can register even when WordPress does not allow registrations.

    <?php
    /**
     * Plugin Name: M2 Open Registration
     * Description: Always allow guests to register a new account in M2, regardless of the WordPress setting.
     * Version:     1.0.0
     */
    
    add_filter( 'ms_member_can_register', '__return_true' );

    Let us know how it worked :wink:
    I just tested it on my Mulitsite installation and confirmed that the code works, so I'll resolve the thread for now. Feel free to reopen in case you need further assistance with this task.
    Thank, Philipp :slight_smile:

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.