Answer Piping Guide

Introduction

Please note that this feature is exclusively available with specific pricing plans.

For example, if someone has answered the question "Your Name", you can then add their answer (like "Mark") to any other part of the form. This is great for making your forms feel more personal.

An image showing the field "Your Name" with the answer "Mark", and a subsequent question with a title of "Okay Mark, what's your email?".

In this guide, we'll cover:

  • Where you can use Answer Piping
  • Where you can't use Answer Piping
  • How to set up Answer Piping
  • Setting a Default Answer using Answer Piping
  • Supported Question Types
  • Answer Piping Transformations

Where can I use Answer Piping on my form?

Answer Piping can be used to insert answers into:

  • Question Titles
  • Question Descriptions
  • Appointment Event Configuration Text
  • General (body/ content) Text
  • Custom Success Pages
  • Custom Emails
  • Custom PDFs
  • Integration Actions

Where *can't* I use Answer Piping?

Although Answer Piping is widely supported throughout Paperform, here are some areas where you can't directly use this feature.

  • Custom Question IDs
  • Multiple Choice/Dropdown Options
  • Calculation Fields within other Calculation Fields

Calculation Fields cannot be Answer Piped into other Calculation Fields, but the value of Calculation Fields can be used as normal with any other supported area on your form.

How do I set up Answer Piping?

The Fast Method


  1. Navigate to the area you'd like to add Answer Piping to.
  2. Begin by typing two forward-facing curly brackets ({{) and then type the title of the question you're trying to use in answer piping.
  3. A dropdown list will appear for you to select the question you're trying to use. Clicking on the desired option will then complete the Answer Piping for you. e.g. Your Name
Screenshot of the text "{{ your..." with options for questions to select underneath.

If the question being piped is the first one in the list, you can press "Enter" on your keyboard to complete the Answer Piping text.


The Long Method

  1. Click on the question you want to pipe the answer from.

  2. Copy the Question ID from the top of the right sidebar.

    If you'd prefer, you can customize the Question ID at the bottom of the right sidebar. Ensure your ID doesn't contain any spaces or special characters, e.g. *@!"£$%^&()**.

  3. Wherever you would like to pipe the answer, paste the question ID between double curly braces.

For example, to pipe the answer to a question with an ID of e7jcq, you would use:

{{ e7jcq }}

You'll know whether Answer Piping is working by clicking outside of the area you're editing. You should see a bubble appear in the area your Answer Piping code was added instead of the code itself. The bubble will also contain the Question Title to determine which question is being piped in.

A field in the form editor showing text in the question title, containing a dark-colored bubble indicating Answer Piping is present. The bubble contains the question title of the field being piped into this text.

If the Answer Piping bubble does not appear, this generally means that the Answer Piping for this field isn't working. Be sure to check that the Question ID is correct (either custom or default), and that you're not attempting to use a calculation field within another calculation field.

Piping values other than answers

There are also some values that you can use for Answer Piping which don't come directly from user-submitted answers.

There are also several values which may be piped in limited places (such as {{ submitted_at }}, which can only used in post-submission actions like outgoing emails and direct integrations).

Setting a Default Answer using Answer Piping

Due to the fact that Answer Piping updates in real-time, your form content can look a little strange when using answers from fields the respondent hasn't answered yet.

For example, if you want to pipe the answer for "Your Name" into the following question ("Hey {{ name }}, what’s your email?"), then the question title might look a bit weird before the person has entered their name.

An image showing how answer piping may look when no answer is provided for the piped field, and no default answer is set. The answer piping shows up as blank whitespace which can cause confusion for form respondents.

You can set a default answer to appear before the customer has given an answer to make forms read better. This is especially useful if you are piping answers that are not required and may not be answered.

For example, you may want the email question in the last example to say "Hey there, what’s your email?" if the name question isn't answered.

You can set a default value using this format:

{{ id |default}}

Let's try changing the email question's title to: "Hey {{ name | there }}, what’s your email?"

An image showing how a form field may look when using answer piping with a default value. This means that when no value is entered for the piped question, it will revert back to the default value set on the form.

Once the field is answered, this will be piped in place of the default value:

An image showing how a form field may look when using answer piping from a field that contains an answer provided by a respondent.

Answer Piping Question Types

Most question types will permit the use of regular Answer Piping (e.g. {{ id }}), however, sometimes you may need finer control over answers being inserted from complex fields.

The question types listed below support more advanced answer piping features that allow you to access additional properties. These additional properties can be particularly helpful in calculations and are accessed via "dot notation" on the answer piping key.

For example, {{ a3fda.selectedProducts }} will return a list of all the selected product SKUs.

In the examples below, id is a placeholder for the question ID and sku is the placeholder for a product's SKU. Make sure that id and/or sku are replaced with your actual question IDs/product SKUs, or they may not work as intended.

Question types

Address

Standard address questions:

  • {{ id.street }} — The street field
  • {{ id.suburb }} — The city/suburb field
  • {{ id.state }} — The state field
  • {{ id.postcode }} — The zip/post code field
  • {{ id.country }} — The country field

Address questions using Google Address Search:

  • {{ id.subpremise }} — The apartment/unit
  • {{ id.streetNumber }} — The street number
  • {{ id.street }} — The street (not including number)
  • {{ id.suburb }} — The city/suburb
  • {{ id.state }} — The state
  • {{ id.postcode }} — The zip/post code
  • {{ id.country }} — The country

Appointment

  • {{ id.start }} — Datetime and timezone for the appointment start
  • {{ id.start_rfc3339 }} — Datetime and timezone for the appointment start, formatted as RCF3339.
  • {{ id.start_timestamp }} — The timestamp for the start of an appointment, formatted as milliseconds.
  • {{ id.start_date }} — Start date of the appointment
  • {{ id.start_time }} — Start time of the appointment if it is in minutes
  • {{ id.stop }} — Datetime and timezone for the appointment end
  • {{ id.stop_rfc3339 }} — Datetime and timezone for the appointment end, formatted as RCF3339.
  • {{ id.stop_timestamp }} — The timestamp for the end of an appointment, formatted as milliseconds.
  • {{ id.stop_date }} — End date of the appointment
  • {{ id.stop_time }} — End time of the appointment if it is in minutes
  • {{ id.title }} — Title of the appointment
  • {{ id.location }} — Location of the appointment
  • {{ id.description }} — Description of the appointment
  • {{ id.minuteLength }} — Length of the appointment in minutes
  • {{ id.hourLength }} — Length of the appointment in hours
  • {{ id.dayLength }} — Length of the appointment in days
  • {{ id.timezone }} — Timezone of the appointment

Color Picker

  • {{ id }} — The selected color's hex code (e.g. Black is #000000)

Country

  • {{ id.code }} — The two-letter country code
  • {{ id.name }} — The full country name

Date

  • {{ id.year }} — The selected year
  • {{ id.month }} — The selected month
  • {{ id.day }} — The selected day

Matrix

  • {{ id }} — A list of the selected options, labeled by row
  • {{ id.rows.row }} — A comma-separated string of the selected options for that row number, labelled by column (e.g. key.rows.1 is the first row)
  • {{ id.cells.cell }} — Whether a cell is selected or not using Excel-style coordinates, labelled as true or false (e.g. id.cells.A1 is the first column in the first row)

*Does not work for questions that allow more than one answer

Price

  • {{ id }} — Total price for a price question (will keep the price even if not visible)
  • {{ id.total }} — Total price for a price question (will be 0 if question is not visible)

Products

  • {{ id.quantity }} — Total quantity selected for the question
  • {{ id.selectedProducts }} — Array of selected product SKUs
  • {{ id.quantities.sku }} — Selected quantity for a product SKU
  • {{ id.names.sku }} — Name of a product
  • {{ id.prices.sku }} — Price of a product
  • {{ id.total }} — Total price for a product question (will be 0 if question is not visible)

Rank

  • {{ id }} — An ordered list of the ranked options selected.
  • {{ id.array }} — An ordered array of the ranked options selected.
  • {{ id.commaSeparated }} — An ordered comma-separated list of the ranked options selected.

Rating

  • {{ id }} — The number correlating to the rating selected (e.g. a rating of five symbols is equal to 5)

Time

  • {{ id.hour }} or {{ id.hour12 }} — The hour in 12 hour format
  • {{ id.hour24 }} — The hour in 24 hour format
  • {{ id.minute }} — The minute
  • {{ id.ampm }} — The time period

Transformations

There is one more set of answer piping features that can come in handy. Transformations allow you to modify an answer piping value using the following formats.

With a default value {{ id | default_value | transformation }}

Without a default value {{ id || transformation }}

Remember to replace id with the ID of your actual question. Without this, the Answer Piping Transformation will not work.

Available transformations include:

  • uppercase - {{ id | "default" | uppercase }}
    Transforms the answer to uppercase, or "default" to "DEFAULT"
  • lowercase - {{ id | "DEFAULT" | lowercase }}
    Transforms the answer to lowercase, or "DEFAULT" to "default"
  • capitalize - {{ id | "default" | capitalize }}
    Transforms the answer to proper case, or "default" to "Default"
  • encoded - {{ id | "support@paperform.co" | encoded }}
    Applies percent-encoding to the answer, or changes "support@paperform.co" to "support%40paperform.co"
  • date - {{ id | "2019-12-31" | date d/m/y }}
    Transforms the answer to the entered date format, or changes "2019-12-31" to "31/12/19"

Gotchas

  • Answer Piping cannot be used within a Calculation field if the answer being piped is from another Calculation field.
  • Calculation provide a Live Preview using Answer Piping your latest form submission. If you're Answer Piping properties from questions that haven't been answered yet, you may see some unexpected results. To resolve most issues related to this, simply answer the relevant question in a new submission on your form.