Time to sketch out the structure of my caching RTE code. Just to recap, here’s the current version of the VSSCORM RTE which has no caching mechanism – all transactions are immediately reflected in the persistent storage (LMS database).
The server-side setValue.php and getValue.php functions will no longer be needed – all LMSSetValue() and LMSGetValue() API calls will interact with the cache on the client side (the browser) – but I will need to create a new commit.php function to handle the LMSCommit() API call.
Finally, I need somewhere to locate this cache and, rather than create another document/file/frame, I’m going to locate it in the header of the ‘api.php’ file. This makes sense because it’s also where the LMSSetValue and LMSGetValue functions are implemented.
Next time – create the cache code in api.php.