Force clearing browser cache using Lectora
March 4, 2014 12:00 AM
Hi there,
I am experiencing an issue where clients are accessing courses with older content because their cache has not been cleared. Is it possible to implement a way where the Lectora course can force clear the user's browser cache when the course is launched? Would this affect bookmarking if it is applied?
Thanks!
Discussion (2)
Cache control should ideally be the server prerogative, so you should talk to the web server administrator. In SCORM, clearing cache or cookies does not affect bookmarking. In simple over-the-web delivery, clearing cache shouldn't affect bookmarking, and clearing cookies will delete the bookmark.
However, you can execute window.location.reload(true) in JavaScript to force no-cache reload of the whole page. The problem is, it will most likely cause issues in an LMS (e.g. the LMS will close the window).
Hi Sergey,
I'm experiencing a similar issue where a server-deployed HTML course is showing all Main Menu chapter items as accessible when a learner loads the course (only Chapter 1 should be unlocked at the beginning of the course, with subsequent chapters being unlocked upon completion of the previous).
This learner has been through the course before, but should get a 'fresh' course every time they open it (it should not remember or bookmark their position).
I tried adding an OnPageShow JS window.location.reload(true) action on my opening screen to flush the cache, but it appears to break the course and the first page doesn't load at all.
Do you have any tips for the best placement of this action?
Cheers,
Cam
Discussions have been disabled for this post