Zathan
Manual says...
[quote:1g4j0hvh]Local vs. Session storage
The WebStorage object allows data to be stored in two places: Local storage and Session storage.
Local storage is permanent (until the user clears their cache). If the user comes back the next day, local storage still has the saved data.
Session storage only lasts with the current browser session. If the user comes back the next day, session storage is empty again.
Cache is not cookies, big difference. Cache is wiping all browser data, basically making the browser start from scratch.
You cannot install something on a users computer that he/she doesn't have the ability to delete.
If you want permanent data that user can not delete, then you must store data in external server and connect the game to that server to retrieve that data.
Webstorage is your best/easiest option. And local is permanent, and session is only lasts till user closes his browser.
The save/load also stores an array entry into webstorage.
If the user wipes his cache, then he wipes your saved game data, but also all data from all websites and he obviously wants to do that, which he is allowed to do - its his machine.
Ah, great explanation! Now is clear to me.
Thank you.