User Registration for Free Course with Invitation Code


I am trying to create a registration for a free course, only available to people with an invitation code that they will be given when they purchase a physical product. I want to direct them to a specific registration page only for the membership related to that product. I do not want them to see other available memberships on the registration page – just take them straight to a registration form for the relevant membership.

I also want the registration process to be nice and simple, one page to register and then direct them straight to the membership content – inputting the invitation code on the one-page form. Since it is a free course not requiring payment, there is no purpose to send them to another page just to enter the invitation code.

It seems that there are a lot of people who have posted wanting the same sort of thing but from what I’ve seen on the support forums it’s not available… is this correct? If it is possible to do, can you please provide information for how I am best to implement this?

I was trying to create a custom registration form using another plugin (Registration Magic) and I can use the shortcode [ms-membership-register-user membership_id=”ID”] to register them to the membership, however I cannot work out how I would add the Invitation Code to this…?

Just recapping what I’m hoping to achieve:

1) Unique Registration Form for a Specific Membership only

2) One page registration form with invitation code (free course so no payment required)

3) Take them straight to the membership content after registration.

Thank-you for your help!

  • Predrag Dubajic
    • Support

    Hey Sonya,

    Hope you’re doing well :slight_smile:

    For this kind of setup it would be best using the shortcode that you already mentioned: [ms-membership-register-user membership_id=”ID”]

    The form itself will not show the invitation code field as this is just a registration form, it will not apply membership right away, instead, once the account is registered and you go to next step where you can enter invitation code to join that membership.

    Once that is completed it redirects to a Thank You page that you have selected under Membership 2 > Settings panel.

    You can either select different page that will have your desired content or you can simply edit the current one and instead of link to Account page add your own URL to a page you want to link on thank you page.

    Best regards,


  • Sonya
    • Flash Drive


    As I said I was wanting it to be all on one page, not requiring multiple pages to register. I have seen several other people requesting the same thing so I think this is really something that should be considered as a feature update. It feels very clunky as a user to go through this process.

    Also, I noted when I tested this, that this is even more clunky because after going to the second page to add the invitation code and click on APPLY INVITATION the page then reloads (to page 3 from a user experience) and then you have to click on SIGNUP to actually register. As stated I’m really wanting a very simple fast and easy ONE PAGE sign up as this is really not a great user experience for something that should and could be much more simple.

    After the person finally signs up 3 pages later, it then comes up with this message:

    “The Payment Gateway could take a couple of minutes to process and return the payment status.”

    As this is a free access program only requiring the invitation code, this is a very confusing message. How can I change this so it just takes them straight to their membership content and does not display this message?

    Please note:- I don’t want to set a different thank-you page as I will have multiple memberships and I want it to take them to the content specific for the membership that they just signed up for, not a generic thank-you page. (I note that other membership plugins allow you the option to set a specific page to take users to after they have registered – unique for each membership, but I don’t see that option in Membership 2 Pro – perhaps another feature to add).

    Also, on Step 2 and 3 of the Registration form, Can I change what it says on this page? I don’t want to use the terminology “Membership” or “Invitation Code” as this doesn’t really make sense for my purposes.

    Currently, this page says:

    “Join Membership

    Please check the details of the membership below and click on the relevant button to complete the signup.


    You need an invitation to register for this Membership


    I was looking at creating a user registration form using another plugin so that I could streamline the process, however the shortcode stated inputs the Membership 2 registration form. If there is no way to make your own registration form more streamlined, is there any shortcodes or other tricks to get a user added to the membership using a custom registration form created with a different plugin? And ideally allow inputting the invitiation code as well?

  • Adam Czajczyk
    • Support Gorilla

    Hello Sonya!

    The registration “flow” would be a bit simpler – when using shortcode mentioned in previous posts – if there was no invitation code. It still wouldn’t be a “one pager” but at least one step less. However, currently the invitation code feature works in a way that the code has to be provided and is being applied after the user account registration and membership selection. Then after user puts the code into the form, that code must actually be send to the plugin – so that takes additional step (“page 3 from user’s point of view”:wink:.

    That being said, I have moved this thread to our “Features and Feedback” forum as a “feature request” so other Members of our Community could also vote for the “simplification” of that registration process.

    As for the other ways to “streamline” the process. Currently you can actually use “3rd-party” forms for registration, regardless of whatever plugin/tool you used to create them. You would need to disable Membership 2 Pro registration first, though. You can do this by adding following line to the “functions.php” file of the current theme of your site:

    add_filter('ms_frontend_handle_registration', '__return_false');

    However, while this way will let you built and use any form you like for registration, it will not provide any kind of “integration” with Membership 2 Pro. Therefore, user will not only have to register but will still need to go through all the additional steps to sign up for a membership and provide invitation code.

    That can be solved with some custom coding though based on the API of the plugin that you used for creating registration form (if there’s any available, e.g. Gravity Forms provide a lot of ways to interact with forms via custom code) and the Membership 2 Pro API (which is documented in plugin on “Membership 2 -> Help -> API Docs” page). The basic idea is that if you’re able to gather any necessary information from some form, you could use Membership 2 Pro API to assign a membership to the user. The “tricky” part here would be to validate invitation code as this would have to be fetched directly from the database. Invitation code are stored there as custom posts of “ms_invitation” type (and it’s associate meta data).

    That however would require custom development so you might want to consider posting a question on our “Jobs & Pros” job board here (please note: no WPMU DEV staff involved!) if you need this to be developed for you:

    Kind regards,


  • Sonya
    • Flash Drive

    I was able to achieve what I wanted using the free plugin – Paid Memberships Pro with WooCoomerce integration (setting up a coupon) and using the One Page Checkout plugin (which I got for only $12) and then I removed a few of the checkout fields for a nicer customer experience (using this tutorial as a basis – )

    It is unfortunate that I was unable to use memberships 2 for this basic setup. Hopefully, in the future, it will be updated for a better customer experience.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.