Placeholders in Survalyzer

Note: Each placeholder must have double curly brackets “{{” and “}}” to work correctly.

To view all available placeholders:

  1. Open the RTE window.
  2. Click the Placeholder icon in order to extend this window with all available placeholders.
Sample / Panel placeholder (professional user)

Sample / Panel placeholders are also available to use in surveys. To use Sample / Panel placeholders, take a look at Message placeholders.

Question placeholder

Question placeholders can be used within a survey to show answers to preceding questions.

Note: Question placeholders do not have any prefix. If the question code is “q1” then the placeholder is {{q1}}.

By using a question placeholder you can, for example, show the given answer to a question within the question text of a later question:

Example: Let’s say you ask in question A (let’s assume the question code is qA) which product a respondent most prefers. In question B, you ask them why they most prefer “Product X”. The placeholder for “Product X” is {{qA}}.

In rare cases you don’t want to see the label of the given answer, but rather the corresponding value. In this case, you can get Survalyzer to also show the value (or code) by using additional syntax.

Example: If you use a single choice question (let’s give it the code “q1”) each option has a code, which also can be seen as a value. So if you want to show the value instead of the label it would look like this: {{q1.code}}

Another value that can be shown, is the count of choice (this only works with single choice questions – Single Choice, Discrete Slider, Drop-down). Count means the number of respondents who selected this particular option in this survey at the time when the respondent is completing it. In this case, you can also get Survalyzer to show the count, again by using additional syntax.

Example: If you use a single choice question (let’s give it the code “q1”) with two options, and you want to show the respondent which option was selected most to date. Here you can show the count (instead of the label for the second option) by using: {{q1.count(2)}}
The text in the standard brackets (in example 2) is the code of the answer option.

To understand how your variable name is created and defined, please take a look at “Calculations & Variable Names”.

URL Variable placeholder (professional user)

In Survalyzer, each survey has 20 URL variables by default. For more information please take a look at the URL Variables page.

As a placeholder, a URL variable looks like this: {{url.var01}}

So we have a prefix of “url” here, followed by the variable number. Since URL variables are numbered from 1 to 20, you can’t name these. One digit numbers always have a preceding 0, so it’s {{url.var01}} and not {{url.var1}}

Survey placeholder

Survey placeholders can be used in certain cases. Survey placeholders always start with the prefix “survey” followed by the placeholder name.

{{survey.answers_pdf}}

This placeholder gets replaced by a link to download a PDF file. This file includes all survey questions and the answers provided by the respondent. This link can be set up on the thank you page. Click here for a description of this procedure.

{{survey.answers_pdf_all}}

This placeholder gets replaced by a link to download a PDF file. This file includes all survey questions for the respondent. This link can be set up at the start of a survey. Click here for a description of this procedure.

{{survey.language_selector}}

This placeholder gets replaced by the language selector. This is useful if you want to show the language selector on the first page of the survey, when you can use this placeholder in a textblock.

{{survey.locale}}

This placeholder gets replaced by the code of the language (for example, “en” for english) the respondent is currently using. This may be useful for links where you can add the locale to your URL.

This placeholder is actually not needed in the context of a survey. If you want to create a personal link for a survey, please refer to the next placeholder.

This placeholder will be replaced by a freshly created, personal interview link. The ‘id’ must be replaced by the ID of the target survey. You’ll find the ID of your survey in the URL of the build page or in the survey list in the first column.

For example:

target survey build page URL:
https://documentation.survalyzer-eu.app/workspace/4552/survey/21751/build

placeholder example:
{{survey(21751).interview_link}}

Example: When someone registers to your Panel by filling out your registration survey, you can send them an invitation out of the registration survey to the profile survey by creating a personal interview link to it.

{{survey.response_id}}

The response ID placeholder will be replaced by the current response ID (= interview ID) of the respondent. You can use this placeholder to give an anonymous respondent the opportunity to fill out their survey on another device.

This can be achieved when you create a link as follows:

Anonymous Link:
https://documentation.datacoll.net/mlqaawfylf?l=en

Placeholder:
{{survey.response_id}}

Combined:
https://documentation.datacoll.net/mlqaawfylf?l=en&interviewId={{survey.response_id}}

Result in Survey:
https://documentation.datacoll.net/mlqaawfylf?l=en&interviewId=09CE5986-1E41-4A98-A241-000322075A9E

This link could be opened on any other device / browser to continue the survey from the page where it was paused.

{{survey.count_started}} & {{survey.count_completed}}

The {{survey.count_started}} and the {{survey.count_completed}} each contain the count of respondents. In other words, {{survey.count_started}} contains the number of respondents who have started the survey but did not yet complete it.

The {{survey.count_completed}} contains the number of respondents who have already completed the survey, up to the time the respondent sees the placeholder.

These placeholders can be used in value assignments. In combination with the modulo operator for calculations, it’s possible to create an almost perfect nominal distribution.

Custom Variable placeholder (professional user)

These placeholders get replaced by the value of a custom variable, created by a value assignment. All custom variables start with the prefix “custom”, followed by the variable name.

Note: Certain special characters and also blank spaces will convert to an underscore for the placeholder. For example, if your custom variable is named “My Own Variable” this will convert to {{custom.my_own_variable}}

Updated on November 17, 2022

Was this article helpful?

Related Articles

Need Support?
Please login to your Survalyzer account and use the "Create Support Request" form.
Login to Survalyzer