Turn off the roles dropdown on the user registration form

I’ve just installed S2Member on my LMS theme. I’m using the S2Member registration form and with the “allow open registration” set to true. At this point we’re not going to have any paying members, just restrict the content based on if the user is logged in or not.

But here’s the problem: When the registration form is loaded, it loads a role-dropdown with “subscriber”, “teacher” and “student”. These are all irrelevant, and WP has set “subscriber” to be the default role. It would be much more convenient if this dropdown wasn’t shown at all, and instead the default role was used for all self-registering users.

The S2Member roles aren’t shown at all, not even the free user level. Why?

Lastly, can I use the free user in S2Member as my “subscriber” role, and have it be default for user registration, thus eliminating the need for this dropdown altogether?

Thanks!

The subscriber role IS the free user role in s2Member. That’s how it works by default.

…so how can I modify the dropdown? Or do I need to resort to JS or CSS, which feels insecure?

No-one can answer that question because you haven’t explained how you are generating the form.

I suspect you aren’t using s2Member to do so, in which case you should really ask whoever is responsible for the code you are using.

I installed S2Member, and it took over the registration form for my site, including S2Member-logo and everything. So all this comes from S2Member somewhere. On this form were only five fields: username, email, ROLE, first name, and last name. I haven’t changed anything. And since the role part seems unnecessary, I’m scratching my head how to properly remove it without resorting to hacks.

As for the unwanted roles, they probably come from the theme, which is called LMS. But I can’t remove them from here, since they are essential to the theme’s functionality.

It’s no good saying that you haven’t changed anything, because no-one here knows what it was like before!

If you want help, you need to provide the relevant information. You seem to be under the impression that s2Member only has one way of registering members. It doesn’t; there are many.

And it’s still quite possible that the method you are using doesn’t come from s2Member at all. The presence of the logo means nothing in this regard. I suspect in fact that you are just using the default WP registration form.

This is what my registration form changed to after activating S2Member:

Now, upon further investigation, if I turn off the S2Member registration form, the roles are still there. However, I have another site using the same theme without S2Member, and the roles are not visible in that registration form. That’s why this is quite confusing, given that I’m new to S2Member and its wealth of settings.

As I suspected, that is the default WP registration form. The only thing s2Member is doing to it is changing the logo.

Your problem is almost certainly caused by another plugin that is modifying the form to add a dropdown list of roles.

1 Like