Welcome, Guest
Username: Password: Remember me
The place for more technical questions for those who want to create new pagetypes or bespoke functionality.
  • Page:
  • 1
  • 2

TOPIC: Store Quiz Score In database

Store Quiz Score In database 5 years 1 month ago #1272

  • Sanjit
  • Sanjit's Avatar
  • Offline
  • Fresh Boarder
  • Posts: 4
Hi all,

Do you have any idea on how to store the final quiz scores in database.

Thanks...
The administrator has disabled public write access.

Store Quiz Score In database 5 years 1 month ago #1273

  • John Smith
  • John Smith's Avatar
  • Offline
  • Moderator
  • Posts: 360
  • Thank you received: 55
You would probably have to either add code to the page types or intercept the Scorm tracking api calls, effectively creating your own mini Scorm player...

You can see the code that you would have to work with here github.com/thexerteproject/xerteonlineto...evelop/modules/xerte in both of the scorm folders

John
The administrator has disabled public write access.

Store Quiz Score In database 5 years 1 month ago #1274

  • Sanjit
  • Sanjit's Avatar
  • Offline
  • Fresh Boarder
  • Posts: 4
Thanks John,

I would like to know from where does "You scored 1 / 2" render. I mean which file.


Thanks
Sanjit
The administrator has disabled public write access.

Store Quiz Score In database 5 years 1 month ago #1276

  • Tom Reijnders
  • Tom Reijnders's Avatar
  • Offline
  • Administrator
  • Posts: 807
  • Thank you received: 154
That is done in the following file
modules/xerte/parent_templates/Nottingham/models_html5/quiz.html

At line 190.

The score is in variable myScore, the number of questions in quiz.questions.length.
The administrator has disabled public write access.
The following user(s) said Thank You: Sanjit

Store Quiz Score In database 5 years 1 month ago #1352

  • John Smith
  • John Smith's Avatar
  • Offline
  • Moderator
  • Posts: 360
  • Thank you received: 55
I wouldn't mess around too much with those page model files if you can help it Sanjit, otherwise you end up with files that can't be overwritten with the latest bugfixes, etc.

Otherwise when a new version of quiz.html is release and if you wish to use any of the new features or bug fixes then you will need to manually merge your changes into the new file.

You could also intercept what is tracked back via Scorm by modifying one of these xttracking files

github.com/thexerteproject/xerteonlineto...ction%28&ref=cmdform

John
The administrator has disabled public write access.
The following user(s) said Thank You: Sanjit

Store Quiz Score In database 5 years 1 month ago #1364

  • Sanjit
  • Sanjit's Avatar
  • Offline
  • Fresh Boarder
  • Posts: 4
Thanks for the update John.. I will look into scorm. I have another Doubt. I integrated Xerte with my application. I used integration.php file.The username, firstname and lastname are passing correctly from my application to Xerte. But when i try to create or edit an object it shows Session Id not Set. What is the matter.

Thanks
Sanjit
Last Edit: 5 years 1 month ago by Sanjit.
The administrator has disabled public write access.
  • Page:
  • 1
  • 2
Moderators: John Smith
Time to create page: 0.301 seconds
Powered by Kunena Forum