How to Send an Email After a Customer Has Filled Out a Form
As an example, let’s say users provide their email when registering. We want to collect more information about them, such as their date of birth. Users will receive a small bonus — a promo code — for providing additional data. We will send a message with this promo code to their email address.
In this case, the form might look like this:
Let's go through the process of creation and configuration of this form step by step, as well as the subsequent communication with the user after they fill out the form.
Step 1. Creating and Configuring the Form
Step 2. Configuring the Import of User Data Into the Database
Next, configure the matching profile settings:
- Profile search mode in the profile database: what data will be used to search for the profile in the database. For example, if you select email, the platform will search for a profile with the same address that the user provided during registration. If the email is found, the platform will update the corresponding profile's data.
- Database to search for a profile: here, select the database in which the user's email address will be searched.
- External data source to search: select the element of your form to take the data from. For instance, if the search is conducted by email, choose the field that corresponds to the user’s email address.
Here you can add as many fields as needed. It all depends on what information the user provides in the form.
In our case, the user is expected to provide their date of birth. Therefore, we need a corresponding field where we will configure:
- Field in the database: which profile field the information will be saved to.
- Action: "Set from".
- Source column: which form field to take this information from.
Make sure that the correct data will be entered into the correct profile field and save the form using the button in the upper right corner.
Step 3. Creating and Configuring Email Templates
Next, we will need two email templates.
- The first one will be sent to subscribers registered in the last 7 days. Here, we will offer them to fill out the form and receive a small bonus.
The second one will be sent to those who filled out the form. Its purpose is to thank the subscriber and offer a promo code.
Step 4. Configuring a Segment and a Regular Mailing
Next we need to set up an updatable segment. Once a week, it will collect new profiles (for example, users registered in the last 7 days) and send an email to them asking to provide their date of birth.
Next, select the message template.
After that, set the mailing schedule. For example, let's specify that the message will be sent at 13:00 on Tuesdays.
Step 5. Sending a Trigger Mailing After the Form is Filled Out
The final step is to send an email to subscribers who filled out the form and provided their date of birth. For this, we will use a trigger mailing.
Select the form and the database. You can also set a waiting time if necessary. But in our example, this is not needed: the email will be sent immediately after the user fills out the form.
Activate the trigger mailing and save it. Now, thanks to the configured form and mailings, the following will happen automatically:
- A new user receives an email asking to fill out the form.
- When the user provides their date of birth, the data is imported into the database and added to the profile.
- Immediately after filling out the form, the user receives an email with a promo code for a discount.
Don't forget to subscribe to the blog newsletter
To stay up to date with all the news and read new articles, join the Craft Marketing Telegram channel






