bleeper
                Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| bleeper [2022/09/06 09:46] – [replace] admin | bleeper [2023/10/05 08:30] (current) – [bleeper - Censor offensive words in text responses] admin | ||
|---|---|---|---|
| Line 2: | Line 2: | ||
| The **bleeper** function censors offensive words in text responses. It flags responses with offensive words and replaces offensive words with alternative characters (e.g., #). The bleeper function can be used on any type of question that contains text responses. Access to a database of offensive words is included, but use of alternative sources is supported. | The **bleeper** function censors offensive words in text responses. It flags responses with offensive words and replaces offensive words with alternative characters (e.g., #). The bleeper function can be used on any type of question that contains text responses. Access to a database of offensive words is included, but use of alternative sources is supported. | ||
| - | This function is available for a reasonable fee. Contact [[https:// | + | This function is available for a reasonable fee. Contact | 
| ===== 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 bleeper function to the survey header to make it available to any question in the survey. | Add the bleeper function to the survey header to make it available to any question in the survey. | ||
| < | < | ||
| Line 19: | Line 18: | ||
| </ | </ | ||
| - | To override the default options, specify the desired [[bleeper# | + | To override the default options, specify the desired | 
| < | < | ||
| Qualtrics.SurveyEngine.addOnload(function() { | Qualtrics.SurveyEngine.addOnload(function() { | ||
| Line 29: | Line 28: | ||
| **addWords** is an array of offensive words to be censored in addition to the offensive words returned by jsonSource. | **addWords** is an array of offensive words to be censored in addition to the offensive words returned by jsonSource. | ||
| - | Default: | + | Default: [] | 
| ==== bleepFlagVar ==== | ==== bleepFlagVar ==== | ||
| **bleepFlagVar** is the name of an embedded data field that captures whether any words were censored by setting its value to 1. To save **bleepFlagVar** in Qualtrics response data, define it as an embedded data field in the survey flow. | **bleepFlagVar** is the name of an embedded data field that captures whether any words were censored by setting its value to 1. To save **bleepFlagVar** in Qualtrics response data, define it as an embedded data field in the survey flow. | ||
| - | Default: " | + | Default: | 
| ==== jsonSource ==== | ==== jsonSource ==== | ||
| **jsonSource** is the url of a webservice that returns a json string containing an array of offensive words. It can be used in place of the default database that contains approximately 470 offensive words in English. | **jsonSource** is the url of a webservice that returns a json string containing an array of offensive words. It can be used in place of the default database that contains approximately 470 offensive words in English. | ||
| - | if **jsonSource** is set to empty ("" | + | if **jsonSource** is set to empty %%("" | 
| ==== removeWords ==== | ==== removeWords ==== | ||
| **removeWords** is an array of words that should NOT be censored even though they are included in jsonSource. | **removeWords** is an array of words that should NOT be censored even though they are included in jsonSource. | ||
| - | Default: | + | Default: | 
| ==== replace ==== | ==== replace ==== | ||
| - | **replace** is a boolean the specifies whether censored words should be replaced. | + | **replace** is a boolean the specifies whether censored words should be replaced. | 
| Default: true | Default: true | ||
| Line 49: | Line 48: | ||
| **replStr** a string used to replace characters in offensive words. | **replStr** a string used to replace characters in offensive words. | ||
| - | Default: "#" | + | Default: | 
| ==== selector ==== | ==== selector ==== | ||
| **selector** a css selector specifying the text input fields within the question that the bleeper function should be applied to.  **selector** can be used to enable bleeper on any type of question containing text responses or specific text responses within a question. | **selector** a css selector specifying the text input fields within the question that the bleeper function should be applied to.  **selector** can be used to enable bleeper on any type of question containing text responses or specific text responses within a question. | ||
| - | Default: " | + | Default: | 
| + | ====== Qualtrics Wiki ====== | ||
| + | [[start|Qualtrics Wiki]] | ||
bleeper.1662471997.txt.gz · Last modified:  by admin
                
                