Creating a Password Recovery DataPage
Password Recovery DataPages allow your authenticated app users to receive their password or a password reset link via email. In order to create a Password Recovery DataPage, your authentication table must include at least a unique email field and a password field.
To create a Password Recovery page open the DataPage wizard by clicking “New” in the DataPages view or by selecting New DataPage from the file menu. Under the Forms DataPage Type Select Password Recovery.
On the DataPage Data Source screen, select your authentication table as the data source. You can also rename your DataPage, and select a Style & Localization. Click Next.
On the Select Fields screen you will need to indicate which fields are being used to hold your User’s Password and Email. If you are using the Password data type the password field should be automatically selected for you.
Then, Select which fields will be used to verify the user’s identity by moving the fields to the right-hand panel using the arrow buttons. All verification fields will be required. Click Next when complete.
On the Configure Fields screen you can configure each of the verification fields as well as add formatting sections such as Header and Footers and HTML blocks. Click Next when complete.
The Configure Email screen allows you to customize the email that your user will receive.
If your password field is using the Password data type the email will contain a Password Reset link. If your password field is using another data type such as Text(255), the user’s password will be emailed directly to the user’s associated email address.
Fields in the Configure Email screen:
- From: Enter the email address that will appear in the “from” field of the email message. This address can either be a monitored email within your organization, or a no reply address such as firstname.lastname@example.org
- Subject: Enter the subject of email
- Message body: Use this area to enter the message text of your email. You can insert dynamic data directly from the user’s record using the Available fields dropdown and insert button immediately below.
- Email format: select whether the email should be rendered as HTML or plain text.
Once you have finished configuring your email message click Next.
On the Destination Page screen you can configure where the user will be directed upon successful verification and upon failed verification. When entering URLs into these destinations be sure to include a protocol (http:// or https://)
If you are using a Password data type field you will also have one additional screen. On the Reset Password Field screen you will be able to configure the Reset Password form. The password will be displayed in password characters (*****) and will need to be entered twice by the user. Using the Insert button you can also insert formatting blocks such as a header and footer and HTML blocks.
Special considerations for the Password Recovery Link:
If you are using the Password data type the Available fields dropdown contains two special parameters.
- #PasswordResetLink: This parameter will insert a link directly to the password reset page deployed using a Direct from Caspio URL.
- #PasswordResetToken: This token can be used to direct the user to an embedded deployment of the Password Reset DataPage.
Embedded Password Reset Pages:
The default reset password link will direct the user to a Direct from Caspio URL. If you have embedded a Password Recovery DataPage into a webpage, you can create a custom link to redirect your user back to that URL. This custom link will include a reset token that will automatically change the Password Recovery DataPage into a Password Reset form uniquely for that returning user.
To create a custom link:
Copy the host URL of your Password Recovery DataPage and paste it into your email’s message body.
Add the following to the end of the URL:
Immediately after the equal sign insert the #PasswordResetToken using the Available fields dropdown.