Looking Up a Form's Submissions
Use Form variable names with the submissions
method to get all submissions to a form.
Liquid Input
{% for submission in FormName.submissions %}
Name: {{ submission.name }}
Color: {{ submission.color }}
{% endfor %}
HTML Output
Assuming the form "Form Name" has two submissions, one named "Submission 1" and colored "Red", and another named "Submission 2" and colored "Blue".
Name: Submission 1
Color: Red
Name: Submission 2
Color: Blue
Looking Up a Connection's Submissions
If you're using a Submission View, or you've set a submission to a variable, you can get sets of submissions from connection fields.
Liquid Input
Connections:
<ul>
{% for submission in self.connection_field %}
<li>{{ submission.color }}</li>
{% endfor %}
</ul>
HTML Output
Assuming the submission is connected to two submissions, with "color" field values "Red" and "Blue".
Connections:
<ul>
<li>Red</li>
<li>Blue</li>
</ul>
Looking Up Submission Field Values
In the example above, we're only using the Color field. To make it easier, you can look up a single field's values with the field's variable name followed by _values
as a method. In the example above, the method becomes color_values
.
Liquid Input
Connections:
<ul>
{% for color in self.connection_field.color_values %}
<li>{{ color }}</li>
{% endfor %}
</ul>
HTML Output
Connections:
<ul>
<li>Red</li>
<li>Blue</li>
</ul>