Want to get response/score of quiz or other games

Hi Team,

Thanks for your previous reply(http://h5p.org/creating-your-own-h5p-plugin).

I have one other question:

1. I embed iframe of one H5P package into HTML page. Directly paste the embed link provided by the H5P package.

2. My package is quiz with some score available with it.

3. Any user visited the site and played the quiz.

4. I want to extract his response/score of quiz and save to database.

I found there are some xapi's provided by your site

My question is, I have javascript as frontend and rails as backend. How can i call Xapis using one of them(js/rails) to get the score?

Or if i  download the h5p package then how can i make it possible  ?

Advance thanks!!

Regards,

Tarun 

falcon's picture

Hi!

H5P is currently not able to provide xAPI statements to a script on an external site that embeds it. It is not straight forward due to security conserns.

If you download the package you have to either make an H5P plugin for your site which will probably take hundreds of hours or you may make the package work standalone which probably involves hours or work since you have to include a couple of things from H5P core  on your site in order to make everything work.

The easiest way forward is probably for you to add features to H5P that allows it to communicate with external sites using Window.postMessage. Will make sure it gets reviewed and merged in quickly if you do. Is this something you would consider doing?