SCORM Activity Iframe

SCORM Activity Iframe

by Robert Koons -
Number of replies: 0

Hello all, long time reader, first time poster.

The backstory: 
I'm a developer working on course activities for my company which are currently delivered thru Moodle (version 2.7). I was hired to build a new system that's mobile friendly for our learners, but still utilized SCORM to log the learner's progress and grades. What I ended up building was an Angular (7) web app that is added to a Moodle course as a 'File' resource. I would also create a blank SCORM package in the course. In order to get the Angular project to report back to the SCORM package I would manually add the `/mod/scorm/loaddatamodel.php` and  `/mod/scorm/request.js` files to the index page of the Angular project. While this is less than ideal, it has been extremely successful.

The problem:
Our company is now upgrading Moodle to 3.5, and `/mod/scorm/loaddatamodel.php` no longer exists. Now the SCORM data is dropped on the parent page of the iframe. So far, the only way i've been able to get this work is by adding the entire bundled Angular app into the SCORM package in Moodle (doing away with the 'File' resource entirely.) This still works well, but phones hate iframes.   The JS gymnastics i'm going thru to try and get this iframe to work on mobile devices is just ridiculous.

Does anyone know of a work around? Either 1) a way to get rid of the iframe, or 2) a different way to access the SCORM data, or 3) something different entirely. I'm not a Moodle developer, so maybe there's something relatively simple that I'm just not aware of.

Thanks!

Average of ratings: -