If you are using the WPForms Pro version you can register users to your site using User Registration addon for WPForms. In this tutorial, we will tell you how you can allow users to update their profile from the site frontend using WPForms Views.
List of plugins we will be using:
- WPForms Pro
- WPForms User Registration Addon
- Views For WPForms Pro
- Views for WPForms – Inline Edit Addon
Step1: Create a User Registration Form in WPForms
- Start by creating a new Form from WPForms => Add New. Let’s name this form User Registration
- Now search for User Registration Template from left sidebar and click on Use Template button.
- This will automatically add 5 default fields to your form & we will be adding 1 more field to store it as user meta.
- Name – To store the user name in the account.
- Username – This will be the username that will be used to log in to the site.
- Email – To store the user’s email in the account
- Password – To allow users to set password for their account
- Short Bio – To allow users to add some words about them. This will be stored in the default Bio field in the user profile.
- Gender – This will be a Multiple Choice Field to store user gender as a User Meta which we will display in the user profile on the site frontend.
- You can add as many fields as you want and collect the information you need. This is how our form looks now will all fields
- Now let’s set up User Registration addon settings. Click on the Settings tab & select User Registration from there.
- You will see the option to map form fields with user profile fields.
- Map fields like shown below. To store Gender, map the Gender field in the Custom User Meta section
Step2: Create a new View & enable the Inline Edit feature in WPForms Views
- To display user info on-site frontend let’s create a new View from WPForms Views => Add New
- Select View type as List & add the fields you want to display on-page.
- Enable Inline Edit for this view from View Settings => Multiple Entries => Enable Inline Edit
Step3: Display User Profile information using WPForms Views
- Copy the view shortcode & add it on-page.
- Remember to click on “Display only logged in user Entries” in View settings so that user only see their entry.
- Clicking on Enable Inline Edit will highlight the editable fields. Click on any field you want to edit, data will be saved instantaneously including any custom user meta.
Does this work only for users registered with WPForms user registration addon?
Yes, it works only for users who are registered with WPForms user registration addon. Views for WPForms can only show entries stored in WPForms. So, if a user isn’t registered and isn’t created using WPForms user registration addon then there will be no entry for them in the backend.