The translate
tag can be applied to survey elements to specify translation instructions. Both the translate
tag and decorator can accept 'y' or 'n' inputs or language codes to specify which languages a survey element should be translated into.
Tag
set list: AGELIST
translate: n
1. 1 - 17
18. 18 - 24
25. 25 - 34
35. 35 - 44
45. 45 - 54
55. 55 - 64
65. 65+
Decorator
set conditioned text: ROWSQ8
1. (e.g., International Brand 1) {if anyChecked($QCNTRY,11)} {translate: n}
2. (e.g., International Brand 2) {if anyChecked($QCNTRY,12)} {translate: n}
3. (e.g., Brand 3 that needs localization) {if anyChecked($QCNTRY,16)}
Details
- The
translate
tag can be added to any survey widget type. It is most commonly used with standalone lists (set lists
), groups, questions, variables, anddefine sheet
. - Questions that have an implicit
invisible: y
tag are automatically excluded from translations. These include all quotas (regular, derived, click balance), variables created withselectby
, coded variables, reporting-only variables, and summary variables. - To include content in a translation that would normally be excluded, include the
translate: y
tag or decorator. - The
translate
decorator is also supported in sheets. - Any content that includes
translate: n
will also be hidden from the Masks applet.
Additional examples
Including content by specifying languages
If a survey has multiple translations, the translate
tag or decorator can be used to specify which languages should include certain content in translations, rather than exclude it.
For r8 software versions, enter the language codes from the 'URL suffix' column here, separated by commas.
1. What's your favorite color? type: radio optsfrom: COLORS translate: spa,ger
For r9 software versions, enter the translation key, separated by commas.
1. What's your favorite color?
type: radio
optsfrom: COLORS
translate: spa-1,eng-2
The language codes shown in both examples above are also compatible with the translate
decorator.
Translating sheets
Any survey spreadsheet content that has "text" in the column header is automatically included in translations. This includes the default "text" column, as well as any user-defined columns. A column labeled "example_text" would be translated; a column labeled "example" would not.
To exclude an entire sheet from translations, use the definesheet
widget with translate: n
.
definesheet: surveyid.mysheetname translate: n
Comments
0 comments
Please sign in to leave a comment.