mcalphabetize
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| mcalphabetize [2022/09/28 20:48] – [Multiple Choice Question] admin | mcalphabetize [2024/02/07 17:52] (current) – [langs] admin | ||
|---|---|---|---|
| Line 4: | Line 4: | ||
| Functionality includes: | Functionality includes: | ||
| * Works with vertical single answer, vertical multi-answer, | * Works with vertical single answer, vertical multi-answer, | ||
| - | * Alphabetizes based on current language | + | * Alphabetizes based on the current language |
| * Supports anchoring of choices to the bottom of the list | * Supports anchoring of choices to the bottom of the list | ||
| * Compatible with **[[mccolumns|mcColumns]]** (a multiple choice responsive columns function) | * Compatible with **[[mccolumns|mcColumns]]** (a multiple choice responsive columns function) | ||
| Line 10: | Line 10: | ||
| mcAlphabetize currently does **not** support choice groups. | mcAlphabetize currently does **not** support choice groups. | ||
| - | This function is available for a reasonable fee. Contact **[[https:// | + | This function is available for a reasonable fee. Contact **[[https:// |
| + | |||
| + | To alphabetize options in side-by-side dropdowns on-the-fly, see **[[sbsSelectAlphabetize|sbsSelectAlphabetize]]**. To alphabetize drill-down dropdowns on-the-fly, see **[[ddAlphabetize|ddAlphabetize]]**. | ||
| ===== Set-up Instructions ===== | ===== Set-up Instructions ===== | ||
| ==== Survey Header ==== | ==== Survey Header ==== | ||
| - | To make the function available to all questions in the survey, copy the function to the Survey Header inside a script tag: | ||
| Add the mcAlphabetize function to the survey header to make it available to any question in the survey. | Add the mcAlphabetize function to the survey header to make it available to any question in the survey. | ||
| < | < | ||
| Line 24: | Line 25: | ||
| Any " | Any " | ||
| - | If " | + | If " |
| === Question JavaScript === | === Question JavaScript === | ||
| Add JS to call the mcAlphabetize function to apply it to the Multiple Choice question as follows: | Add JS to call the mcAlphabetize function to apply it to the Multiple Choice question as follows: | ||
| Line 48: | Line 49: | ||
| Default: [] (nothing anchored) | Default: [] (nothing anchored) | ||
| + | ==== langs ==== | ||
| + | **langs** is an object for mapping Qualtrics language codes to valid JavaScript locale languages for correct sorting. It is only needed if the Qualtrics language code doesn' | ||
| + | |||
| + | If you have created your own language code, you made need to add your language to the langs object if it doesn' | ||
| + | ==== qlang ==== | ||
| + | **qlang** is the Qualtrics language code string that should be used to do the alphabetization. By default, this is the current language of the survey. | ||
| + | |||
| + | Default: %%" | ||
| ====== Qualtrics Wiki ====== | ====== Qualtrics Wiki ====== | ||
| [[start|Qualtrics Wiki]] | [[start|Qualtrics Wiki]] | ||
mcalphabetize.1664412527.txt.gz · Last modified: by admin
