Search code examples
javascripthtmlscormscorm2004

non iframe html transition when using SCORM


i want to use SCORM (ver. 2004) using multiple html pages and i need to switch them using location.href when im using only 1 html file its working as intended. when using multiple files and switching them off with location.href, we get no connection on the new page and cannot initialize new connection because its already initialized.

Thank you very much for your help.


Solution

  • So the connection being Initialized isn't a big deal. But, each page loading and trying to initialize just generates a SCORM warning/error. That technically is a non-actionable error.

    Cons of this approach

    JavaScript has to instantiate on each page - each time. This means it has to pull back down (depending on the features your using) bookmarking, suspend data, etc... So this is where mitigating all this becomes problematic.

    1. When do you terminate?
    2. How can you bookmark or support bookmarking?
    3. What happens if curriculum adds or removes a page later?
    4. Can I limit the number of times I try to initialize?
    5. Will the LMS even allow this (since sometimes they salt and pepper values in the query string)?

    The share-ability barometer on doing this I'd say is ripe with failure and I'd caution against it. Some LMS systems even detect the unload. Can you over come some of the above - sure. But will you be over taken by the rest... absolutely.

    SCO = Shareable content object. And anything that diminishes the shareable part will hurt downstream.

    Alternative

    Use a single page SCO collection defined in a imsmanifest.xml. See https://github.com/cybercussion/SCOBot/wiki/Single-Pages-Managed-by-LMS-Navigation

    Comment

    Hope that helps. I was involved with a project a very long time ago where a architect wanted to do things simple like this, and it really requires some added elbow grease to either support single pages managed by the LMS, a AJAX or IFRAME approach to do it right.