Lua Scripting Resources

Important Update to Custom Scripting

SurveyGizmo's CustomScript Action now supports the LUA programming language.


Legacy Custom Scripting Language Deprecation Plans 

  1. New accounts (created after October 29, 2018) will only have the option to use Lua in scripts.
  2. As of October 29, 2018 Custom Scripting Actions will default to Lua as the scripting type in the Custom Scripting Action for accounts created before this date. You will be able to switch to the Legacy Custom Scripting; though we highly encourage using Lua.
  3. In the long term, Legacy Custom Scripting Actions will be switched to read-only. Read-only scripts will continue to function; you will just be prevented from editing. The exact date on this is to be determined; we will send notifications well ahead of time.


 Go to our Legacy Scripting Documentation.

While SurveyGizmo is one of the most flexible survey tools around, we get requests for customizations that are not available out of the box. This is where JavaScript and Custom Scripting can save the day. If you have scripting chops you can use the JavaScript action or the Custom Scripting action to achieve the survey of your dreams.


New Articles

  1. lprint

    This function was primarily created for outputting the list function to the page as the Lua print function results in merge code errors within the survey.  Parameters Description Required contents the contents you wish to print true ...
  2. luadecrypt

    Decrypts the given encrypted string. Parameters Description Required string the string you wish to decrypt true key the string key/password used for encryption/decryption true ciphertype a string calling the cipher algorithm ...
  3. luaencrypt

    Encrypts the given string. Parameters Description Required string the string you wish to encrypt true key the string key/password used for encryption/decryption true ciphertype a string calling the cipher algorithm used by en...
  4. tableshuffle

    This function shuffles the elements of a Lua table. Parameters Description Required array the array you wish to shuffle true Example The below example creates a new array and sets it equal to the original array that has been sh...
  5. Control the Survey Taker Experience

    From disabling the enter key to preventing respondents from selecting text in your survey, these JavaScript examples allow you to control the survey taker's experience.
  6. JavaScript Question Customizations

    These question customization scripts cover commonly requested functionality that is not available out of the box with survey questions. Most JavaScript question customizations change the behavior of the questions during survey taking. Whereas, Cust...
  7. Survey Customization Scripts

    These survey customization scripts cover commonly requested functionality that is not available out of the box.
  8. Question Customization Scripts

    These question customization scripts cover commonly requested functionality that is not available out of the box with survey questions. Most Custom Scripting question customizations affect the data that is collected, e.g. transform the data for repo...
  9. Disqualification Scripts

    These disqualification scripts cover commonly requested disqualification functionality that is not available with our built-in disqualification feature.
  10. Randomization: Keep two options together

    When randomizing answer options customers often wish to keep to options together. That is, they wish for the options to randomly move about in the list of all answer options, however, they want them to remain together as a group. While we don't have...