quizname_DoFSCommand(command, args)
Where quizname is the name of your quiz.
Within that function there are four commands of interests: WFQuestionSequence, CMISetScore, MM_cmiSendInteractionInfo, MM_cmiSendSurveyInteractionInfo.
1. WFQuestionSequence: The order in which the questions arrive (useful in random ordered quiz):
var myArgs = new String(args);
if (command == "WFQuestionSequence")
// store the datamy
Args contains the order, separated by <space>s
2. CMISetScore : The user score (note that "survey" questions are not included in the scoring:
var myArgs = new String(args);
if (command == "CMISetScore")
// store the data
myArgs contain the score
3. MM_cmiSendInteractionInfo: Answers to non survey questions:
var myArgs = new String(args);
if ((command == "MM_cmiSendInteractionInfo")
// store the data
myArgs contain the following information, separated by commas.
date => date the quiz is taken in year/month/day format
time => time the quiz is taken in hours:minutes:seconds format
interationId => the question number
objectiveId => not used in Wildform Quiz
interactiontype => "F" for Fill The Blank; “S” for Sequencing; “M” for Matching; “C” for MultipleChoices; “T” for True Or False
correctResponse => correct reponse (format varies by question type)
studentResponse=> correct reponse (format varies by question type)
result =>“C” if user answered correctly, “W” otherwise
weight => always 1
latency => not used in Wildform Quiz
Example: 2008/06/09;22:21:29;Slide_2;;C;0;0;C;1;null
Note: this command is sent when user clicks the Submit button, or at the end of the quiz. At the end of the quiz, questions on which the users had not clicked the Submit button are submitted and each question will trigger this event, unless the user did not answer the question. If the user did not answer the question, the interpretation is up to you. To see the message being passed, add a JavaScript alertbox inside the quizname_DoFSCommand(command, args) function.
4. Answer to survey questions:
var myArgs = new String(args);
if ((command == "WF_cmiSendSurveyInteractionInfo")
// store the data
myArgs contains the same information as in #3 above.
Note that there is no wrong or right answer in survey questions, so the answer will not count towards the score.
|