1. Home
  2. Docs
  3. Addons
  4. Extra Template Variables

Extra Template Variables

The Quiz and Survey Master Extra Template Variables is an add-on that will give you access to more template variables that can be used in the results pages and emails. Allowing you to customize your emails and results page more.

INSTALLATION/SETUP

Once you have purchased the addon, you will have access to download the addon. To install, simply upload the addon as a normal WordPress plugin. To do so, go to the Plugins page and click Add New. Then, click Upload. From there, upload the zip file that you downloaded when downloading the addon.

Once the addon has uploaded, you should now have the plugin QSM Extra Text Variables listed in your list of plugins. Then all you will need to is click Activate to activate the plugin.

SETTINGS/CONFIGURE

Before you can use the Extra Variables add-on, you must first enter in the license key.

Adding Your License Key

QSM Certificate - Adding Addon License Key
QSM Extra Variables – Adding Add-on License Key

Enter your license key from your account into the “Addon License Key” field on the “Extra Variables” tab of the “Addon Settings”.

Once you have entered your license key, be sure to click “Save Changes” to save the page.

After adding the License Key, you can now use the newly added variables while editing your quizzes or surveys.

QSM- Extra Template Variables - Updated 2021
QSM- Extra Template Variables

AVAILABLE VARIABLES:

  • %QUESTION_ANSWER_CORRECT% – This variable shows all questions and answers for questions the user got correct.
  • %QUESTION_ANSWER_INCORRECT% – This variable shows all questions and answers for questions the user got incorrect.
  • %QUESTION_ANSWER_GROUP%%/QUESTION_ANSWER_GROUP% – This variable shows all questions and answers for questions where the user selected the matching answer. For example, %QUESTION_ANSWER_GROUP%Always%/QUESTION_ANSWER_GROUP% would show the questions and answers for questions where the user answered “Always”.
  • %CUSTOM_MESSAGE_POINTS%%/CUSTOM_MESSAGE_POINTS% – This variable shows a custom message based on the number of points a user has earned. For example, you could say “Based on your points, you are a ____” where blank is the custom message. For usage, %CUSTOM_MESSAGE_POINTS%loser:0-49;winner:50-100;%/CUSTOM_MESSAGE_POINTS% where the loser would be shown for users with points between 0 and 49 and winner would be shown for users with points between 50 and 100.
  • %CUSTOM_MESSAGE_CORRECT%%/CUSTOM_MESSAGE_CORRECT% – This variable shows a custom message based on the score a user has earned. For example, you could say “Based on your points, you are a ____” where blank is the custom message. For usage, %CUSTOM_MESSAGE_CORRECT%loser:0-49;winner:50-100;%/CUSTOM_MESSAGE_CORRECT% where the loser would be shown for users with a score between 0 and 49 and winner would be shown for users with a score between 50 and 100.
  • %QUESTION_POINT_SCORE% – This variable shows the number of points allotted to each question in the Quiz/Survey and displays it at the end of the quiz. One of the ways to use this variable with %QUESTIONS_ANSWERS% in the Text Tab of the Quizzes/Surveys Plugin.
 

EXAMPLES:

The below image depicts the configuration done on the results page of the demo quiz

QSM- Extra Template Variables -2- Updated 2021.png
QSM- Extra Template Variables – Adding Variables

And, the following are the results:

QSM- Extra Template Variables -Final Results- Updated 2021.png
QSM- Extra Template Variables – Final Output – Positive
QSM- Extra Template Variables -Final Results Negative- Updated 2021.png
QSM- Extra Template Variables – Final Results Negative

Also, an example of the Question Points Variable can be seen below.

QSM- Extra Template Variables - Question Point Score Variable - Updated 2021.png
QSM- Extra Template Variables – Question Point Score Variable in Action

If you have any trouble implementing the extra variables or have more questions about the process, please fill out a support ticket by going to the WordPress dashboard and selecting ‘help’ in the QSM plugin and our support guru will be able to help you.