How to Use Gravity Forms to Unlock Password Protected WordPress Content

There are many occasions when you want your users to provide some information to unlock your premium content, such as their name, email, or address. In such cases, you can choose one of the following options:

  1. Add extra input fields to the default password form
  2. Add a password field to a contact form

In this article, we will show you how to display a password field under Gravity Forms and use it to unlock protected content.

If you don’t want users to have to enter a password, send them a quick access link after form submission instead.


How to add password field to Gravity Forms

Once activating our plugins, navigate to Forms and edit the form that you want to add the password field.

Your form needs to contain at least one “Single Line Text” field which will be the password field.

At the top menu, hover over Settings and click on PPWP Pro to see our PPWP Forms Integration configuration.

1. Select “Use this form as central password form”

Select “Use this form as central password form” option from “Form Action” dropdown.

This option requires your users to enter a password during the form submission process. Once done, users will be redirected to the private content automatically.

2. Attach a protected page to the form

Select the private content to be sent to users after form submission by inputting its ID. You can get the ID number by hovering over the desired post title.

Make sure the associated content is protected by our PPWP Pro or its extensions such as PPWP Groups or PPWP Access Levels. Otherwise, users will see an error message when submitting the form.

3. Select which form field to be the password field

You can find the field ID by clicking on the field title.

Once done, save the settings and publish or update the form.

It’s worth noting that:

  • Users can unlock specific content using individual passwords or master passwords.
  • Our plugin does not replace the default password form with the custom contact form. So if your users access the protected content directly, they will see a password field only.
  • Once users enter the correct password and submit the form successfully, our plugin will save a cookie to their browser. So they don’t have to re-enter the password when accessing the private content multiple times.
  • To avoid duplicate submission, users will receive an error message if they have already unlocked the protected content.
Lasted updated on September 14, 2020