Exit Course Button Not Working In Moodle, But Works In Lectora

The Exit course button that closes the window does nothing when clicked; when running via moodle LMS.

However when I run the course from lectora the button works as it should. Any ideas why this is happening?

Comments

  • carlfink
    carlfink Community Member Posts: 1,099 ✭ Legend ✭
    Can you give more information? For instance, what does the button do exactly? That is, is it running the Exit Title/Close Window action? Are you publishing the course as xAPI, SCORM (1.2 or 2004), or AICC? Have you tried publishing with "Debug Published Content" turned on? Is the course being launched in a separate window, or in the main Moodle window?

    Carl
  • jawad
    jawad Community Member Posts: 73
    The button is to exit the title/close window. Published as SCORM. Course is launched in seperate moodle window. Published with debug on.
  • jawad
    jawad Community Member Posts: 73
  • carlfink
    carlfink Community Member Posts: 1,099 ✭ Legend ✭
    You published it with debug turned on. What happens (according to the debugger) when you click Exit after launching in a Moodle window? Is that Action triggered at all?
  • jawad
    jawad Community Member Posts: 73
    When I "Run in Debug Mode," I get the following:

    Action [OnMEnterShow on Button] fired!

    Action [OnMClkExitClose on Button] fired!
  • timk
    timk Community Member Posts: 1,239 ✭ Legend ✭
    Hi,

    I've uploaded your example to moodle 3.0 (Scorm 1.2) and the Exit button is working alright, i.e. closes the window. Moodle only supports Scorm 1.2 so you should select "Scorm 1.2 Conformant" from the "Conformance Level" menu. You should check "Launch course in separate window from the LMS" in the Scorm options when publishing, because the Exit button is working differently in a separate window than in the same window.

    Tim
  • jawad
    jawad Community Member Posts: 73
    Thanks guys  - sorted!
  • vicki
    vicki Community Member Posts: 75 ♪ Opening Act ♪
    We have a fix that closes the course window in Moodle when published in scorm2004.

    In the scorm folder, we open the scofunctions2004.js file and change the last line of the doQuit script. The first and last lines of the original coding is:
    function doQuit(bForce){

    if(bForce) parent.top.close()

    }
    We change the last line to be:
    // if(bForce) parent.top.close()

    parent.top.close();
    I would love to be able to make this change in the Lectora source file, but it won't let me save. bummer.
  • timk
    timk Community Member Posts: 1,239 ✭ Legend ✭
    Couldn't you copy the function to a Run Javascript action (all from computeTime() to parent.top.close()) and make the Exit button run that instead of "Exit title / close window"?