Skip to main content

Submit actions

Abstract

A submit action contains actions and verifications performed when contacts click the Submit button.

To submit a web form, a website visitor must click the Submit button. The Submit button may have a different name than Submit, but it is always located under the last web form field section.

B0B76F2CA1CE4E59874D6B741E4C7B0A.png

When a website visitor submits a web form, three types of actions are performed sequentially:

You can use web form verifications to check the values that have been entered in one or more fields in a form. When a user submits a web form, you can set up actions to verify the data submitted in the form.

3C865A53E1994AF4A1EB6B1F85D03863.png

For example, you can use web form verification to check a visitor’s username and password or to verify the availability of a set of selected products against a product database. If form verification fails, the system returns the visitor to the web form, and the error message associated with the form verification is displayed. You can customize an error message for each individual form verification.

In the Web Forms for Marketers module, you can assign actions to a web form. They are performed when the visitor submits the form and all form verifications are successfully completed.

B2DC04A97F154A6AB119BEBE922994A6.png

A save action is a Sitecore item and its purpose is to execute an action implemented in a .NET class. This class is specified in the Class and Assembly fields of the save action item. A save action item is based on the Submit Action template located in the /sitecore/templates/Web Forms for Marketers/Actions/Submit Action folder.

Save action items are stored in the sitecore/ System/Modules/Web Forms for Marketers/Settings/Actions/Save Actions  folder. There are more than a dozen predefined (default) save actions that you can use.

If a save action fails, the visitor is not returned to the form.

A76328B0CB3E457C9ACD35F4FADC6ED4.png

You can add, edit or delete save actions, create custom save actions and modify a save action using a field condition.

You can also configure save action fields.

A success action is a submit action that lets you select either a Sitecore item or a message, which is presented to the visitor after they successfully submit a web form. This is the last of the three submit actions performed during a web form submission.

A56E00FE7C8D42FC85C0EBB672F6D3E9.png

When the visitor successfully submits a form, the success message is displayed on the current page in place of the form. You can redirect the visitor to another page, using the Success Page field.

The pipeline that defines how a success action operates is called the successAction pipeline.

You can also add, edit or delete success messages.