How to Build a Simple Contact Form
This tutorial walks you step by step through building a simple contact form for your website using Motion 2. It is also a good exercise for understanding how Motion 2 works on the back end. The form has First Name, Last Name, Email and Message fields. When an applicant submits it, the form sends an email notification to a group on the admin side that monitors these submissions, then redirects the user to the home page.
Create an entity
- Open CRM > Configuration.
- Under Entities, click Add Entity Group.
- Name the group (for example, Contact Form).
- Right-click the group you added and click Add Entity.
- Name the entity (for example, Contact Form Entities) and select the Is Repeatable checkbox.
- Right-click the entity you added and click Manage Fields.
- Click Add and select the type Text Area.
- Type Message in the Label field and click Save & Close.
Create a group that gets notifications for this form
- Open Users > Groups.
- Right-click the Groups folder and click New.
- Name it (for example, Form Admin) and click Save & Close.
- Add the people who will get the form notifications.
Create a workflow in Motion 2
Add the workflow and its roles
- Open Motion 2 > Workflows. Right-click Workflows and click Add Workflow.
- Name the workflow (for example, Contact Form). If the same person may submit the form more than once, turn on Allow Multiple. Otherwise, a second submission from the same email address is refused.
- On the right side of the window, right-click Primary and click Add Role.
- Name the role Applicant, mark it as the default (main) role, and click Save & Close.
- Right-click Secondary and click Add Role.
- Name the role (for example, Form Admin), select the user group Form Admin, and click Save & Close.
Note: Do not name the primary role "User". If you do, the form will not submit.
A Default status is created automatically with the workflow. To add more statuses, right-click the workflow (Contact Form) and click Manage Statuses.
Add the form task and its fields
- Right-click the workflow and click Add Task.
- Select Form as the Task Type, choose Applicant as the Assigned Role, name the task (for example, Contact Form), and type a Title.
- To hide the Cancel button, tick the Hide checkbox next to it in Task Buttons.
- Right-click the Contact Form task and click Manage Form Fields.
- Add a Person Fieldset, name it Applicant and choose the Applicant role. All CRM fields go inside this fieldset.
- Right-click the person fieldset and add Person Fields for First Name, Last Name and Email. Check the Required checkbox on each.
- Right-click the person fieldset and add an Entity Fieldset, selecting the Contact Form Entities entity.
- Right-click the entity fieldset, add an Entity Field and select Message. Click Save & Close, then close the window.
When you finish, the form fields look similar to this example from another contact form. Your fieldset and field names will differ.

Note: The entity fieldset must sit inside the person fieldset. If it does not, the answers are not saved to the CRM record.
Add the notification and redirect triggers
- Right-click the Contact Form task and click Add Trigger.
- Select Task Completion for the Source field and Send Notification for the Action field. The trigger name fills in automatically.
- Set Apply To to Role, select Form Admin as the role, and type the Notification Subject you want.
- Click the Applicant variable on the right side of the window, then double-click firstname and lastname to add them to the notification body. Reword the body, for example:
{$Applicant.0.firstname} {$Applicant.0.lastname} has submitted a form. Click Save & Close. - Right-click the Contact Form task again and add another trigger.
- This time, select Task Completion for Source and Redirect for Action, then select the home page in the Site Page field. Click Save & Close.
Set up the module in Site Planner
- Open Site Planner.
- Right-click the Modules folder and click Add Item.
- Select Task Sequence in the Module field.
- Name it Contact Form and click Save.
- Select Contact Form for the Workflow.
- Select Contact Form for the Tasks.
- Select the home page as your Default Page and click Save & Close.
The contact form is now ready to be published on any page of your website. Before you share the page, test the form from a private browsing window. See Testing a Motion 2 Workflow and Removing Test Users.
.png)
.png)