Exit Course
March 2, 2023 12:00 AM
This question has been asked in previous threads, but I can't recall finding a solution for it. Here's the issue:
I'm using desktop L21.3 and added an exit button to close the course when done. I tested the button in Edge and Chrome and in the LMS, but it still doesn't close the training. Is there a workaround to get the course closed with the Exit button? It is a requirement in my workplace to add an Exit button to the training and it should be functional.
Thank you!
Discussion (12)
Does your LMS launch courses in a new window (like SCORM Cloud) or in a DIV within its own window (like
Onboard
, the one used by ITS)?
I'm not the LMS Administrator and can't tell, but I'm attaching an image of my SCORM settings. I'm rather concerned about the online format. It doesn't close in Edge & Chrome
My question was, when someone launches a course from the LMS, does it open in different window, or in a marked-off zone of the same page (which is what Onboard does).
Thank you @CarlJFink. When I tested it on LMS staging, it didn't close; so I'm assuming it opened in the same page.
Thanks again,
Lectora buttons run JavaScript under the hood. No JS can close a window unless it was opened by JS, as I understand it. You can't "exit" from an LMS-bound course that doesn't open a new window. For OnBoard, I was playing with a button that executed a "Back" action, but your needs might vary. There might also be an API offered by your LMS to end an elearning course--consult the vendor.
Thanks a lot for the advice, I'll discuss it with our LMS admin. What about exiting the training if it is posted on our website? Will it be possible to close it using my "Exit" button?
Many thanks again!
It doesn't depend on what server the course is launched from. It depends on how the course is launched. If JavaScript launches it in a new window, that window can be closed by script. In this context, a new tab is a new window.
Thanks a lot John, I'll definitely do so. Because we post our trainings on both LMS and Internet, I need to know how to exit the course if the user accesses it on the Internet. Thanks for the above advice from you and Carl, I think I'm good with LMS.
My last question is how to exit the course if the user accesses it on the Internet? Do I need a Java Script? If so, can you send it to me?
Thanks a lot!
Opening the course in its own window is a feature of the LMS. The LMS needs to know where the course is running to properly handle the communication between the course and the LMS.
With an LMS that opens the course on the same page, the Exit button may not work. Course designers with these types of LMS are downplaying the Exit button and adding verbiage to the last page to tell the user what to do next. Usually, it's to direct the user to part or parts of the LMS UI. "Click on the hamburger menu in the upper right", or something like "Choose the next module in the menu below this window."
As
explained and as it behaves on an LMS, the Exit button can't close the same window. However, it can close the course if the course is launched in a separate window. So, the answer is, it depends on how you have the user launch the HTML course.
If you have an HTML page that the user goes to and launches the course, you could add one of the anchor tags below. This simple example assumes you've placed the course in the folder "course" which is the same folder as this HTML page.
The first line below would launch the course in the same window and the exit button WILL NOT work.
Launch in this window
Launch in NEW window
The second line will launch the course in a new window (or tab based on the user's browser settings). In this case, the EXIT button WILL close that window and the user should go back to the original page from where they launched the course.
Another method is to hard code the EXIT button action in Lectora to take the user to the URL of the launch page, which I think is what
was hinting at when he mentioned making the EXIT button a "Back" button.
I hope this is clear.
Thanks a lot Carl. Do you know how to write a JS to open the course in a new window? I'm not a JS person and I don't know how to create one.
Yes, it is clear. Thanks a lot for the script. Let me try and see how it works. I hope it functions well.