Submissions

Similar to Craft Entries, every time a user submits a form, we refer to those as submissions. Currently, submissions can be viewed and edited in the control panel, and displayed on the front end in templates as a list and individually.

In the Control Panel

The list of submissions in the control panel appears very similar to how regular Craft Entries are displayed. You can filter the view by form (or show across all forms), search into submissions, adjust which field columns are shown, and click into any of the submissions to edit them.

Additionally, you can keep track of changes or make private notes by using the Notes feature in the right column of the single submission view inside the CP (similar to older versions of Craft). 3.3.0+

Freeform also includes a chart that gives you a quick visual of how many form submissions your site is receiving.

Submissions Edit Submissions

Exporting Submissions

Freeform includes 3 options for exporting (2 of which are Pro only). Please refer to the Exporting documentation for more information.

In Front End Templates

One common use-case might be displaying the contents of the form submission to the user that submitted it right after they have successfully submitted the form, allowing them to review what they submitted. Of course, be aware that there are security implications here if the submissions contain sensitive content.

If the information is not sensitive, and meant to be public - like comments, you can also display submissions in a paginated (or not) list.

For more information about this, please visit the freeform.submissions template function documentation.

Editing Submissions Pro

Freeform allows you to edit submissions via the front end templates as well. Currently, this feature has no user/author check, and requires you use/provide the submission.token to work (as opposed to the ID). A future version will likely include ability to check on authors, etc. The editing uses the same freeform.form function, but knows you're in edit mode when you feed the submissionToken parameter a valid value.

WARNING

There are currently some limitations with this feature. Please note that:

  • Not all types of forms can be intuitively edited (e.g. Payment forms, some complex ones, etc).
  • Editing Payment forms will NOT update payment details, but instead will make a new submission/charge.
  • Editing forms with Element Connections will NOT update the corresponding element, but just create a new one instead (so currently no editing of user profile data, etc).

When linking to the form edit, you might use something like this inside the freeform.submissions function:

{% if currentUser and currentUser.admin %}
    <a href="{{ siteUrl }}page/{{ form.handle }}/edit/{{ submission.token }}">
        {{ "Edit"|t("freeform") }}
    </a>
{% endif %}
1
2
3
4
5

Then in your template that includes the freeform.form, be sure that the submissionToken parameter is included and checking the URL for a value:

 



 


{% set submissionToken = craft.app.request.segment(4) %}

{% set form = craft.freeform.form('myForm', {
    returnUrl: "{{ siteUrl }}page/{{ form.handle }}/submission/{{ submission.id }}/success",
    submissionToken: submissionToken|default(null),
}) %}
1
2
3
4
5
6

You can also check out the example in the demo templates if you wish to see it in action.

Suppression of Notifications and more

You can apply the suppress parameter to the freeform.form and render functions, which allows you to suppress email notifications, API integrations and Element Connections for a form by passing an object of suppressions you wish to enable, typically used for editing submissions, e.g.:

You can also just set this to true (suppress: true) to enable all suppressions at once.

Examples





 
 
 
 
 
 


{% set form = craft.freeform.form("myForm", {
	id: "myform",
	class: "form-class",
    submissionToken: submissionToken|default(null),
    suppress: {
        adminNotifications: true,
        dynamicRecipients: true,
        submitterNotifications: true,
        api: true
    }
}) %}
1
2
3
4
5
6
7
8
9
10
11

OR





 


{% set form = craft.freeform.form("myForm", {
	id: "myform",
	class: "form-class",
    submissionToken: submissionToken|default(null),
    suppress: true
}) %}
1
2
3
4
5
6
Last Updated: 8/20/2019, 9:02:03 PM