Home › Toolset Professional Support › [Resolved] Auto assign a Role to a user while registering through User Form, based on age.
This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.
Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.
Tagged: Views plugin
This topic contains 1 reply, has 2 voices.
Last updated by Shane 11 months ago.
Assigned support staff: Shane.
I want to auto-assign a Custom Role, based on the user age, when they register to the website through a User Form.
How can I achieve it?
English (English )
Thank you for getting in touch.
The user role is assigned to the user whenever you are creating the form. In order to achieve your query you will need to make use of custom code to check what is the age value the user added to the form and set their user role based on this.
Unfortunately the custom code required to do this is out of the scope of our support forum, however I can point you to the hook that you will need to use to hook into the form when its submitted.
Please let me know if this helps.
Known issues and solutions
Frequently asked support questions
Support tickets archive
Get help from experienced contractors
Meet Toolset support team
Toolset Customer Support Policy
Need to tell us something about the quality of support
How to remove personal information from your database for support