Picture of Todd Routson
SCORM help?
by Todd Routson - Wednesday, 9 July 2014, 3:28 PM
 

Having trouble launching my course in our SCORM environment. My course seems to run fine in the Dev environment, but when I publish it to our SCORM server the course gets stuck on the "Loading" screen. The problem seems to be that adapt.min.js is calling functions like o.LMSGetValue and s.LMSCommit that aren't provided by our SCORM wrapper. I'm not sure why this would be happening; can you provide any insight?

Thanks -Todd

Picture of Matt Leathes
Re: SCORM help?
by Matt Leathes - Wednesday, 9 July 2014, 4:16 PM
 

Hi Todd

I'm not quite sure what you mean when you say "functions like o.LMSGetValue and s.LMSCommit [...] aren't provided by our SCORM wrapper"

Functions like LMSGetValue and LMSCommit are part of the SCORM 1.2 API and are required of any SCORM-conformant LMS.

FYI the 'o.' and 's.' are minified references to the API object. Unminified code would be API.LMSCommit()

Picture of Todd Routson
Re: SCORM help?
by Todd Routson - Wednesday, 9 July 2014, 6:45 PM
 

Thanks for the reply...

Our SCORM API provides API.LMSGetValue et al. The error I am getting through Firebug is:

TypeError: o.LMSGetValue is not a function

Our courses appear within an iFrame but the debugging console found the SCORM version and it was 2004 so it must communicating fine with the API.

Any ideas?

Thanks-Todd

Picture of Matt Leathes
Re: SCORM help?
by Matt Leathes - Thursday, 10 July 2014, 9:30 AM
 

If your API is SCORM 2004, that would explain the problem - there's no function called LMSGetValue in SCORM 2004 - it's just GetValue.

Adapt's SCORM code defaults to SCORM 1.2 - an explanation for why is given in the comments for SCOStart here. If you remove the line

scormWrapper.setVersion("1.2");

Then the code should correctly detect the 2004 API and use the correct functions for that API - however, please note that the SCORM 2004 tracking is completely untested.

Picture of Todd Routson
Re: SCORM help?
by Todd Routson - Thursday, 10 July 2014, 4:55 PM
 

Silly question: where is that line of code you're referring to above? Which file is it in?

Appreciate the help! ;)

Picture of Matt Leathes
Re: SCORM help?
by Matt Leathes - Thursday, 10 July 2014, 5:45 PM
 

ah, of course - the emails from the forums strip the links from text...!

it's here: https://github.com/moloko/adapt-contrib-spoor/blob/master/js/adapt-contrib-spoor.js