Another option for saving data offline in a browser is WebSQL
The Web SQL database API isn’t actually part of the HTML5 specification, but it is part of the suite of specifications
W3C is no longer actively working on the Web SQL Database specification.
Not many browsers support this so only use Chrome or Safari to see examples working
Web SQL database stats: http://caniuse.com/sql-storage
This is the same as the webstorage example so refer to that for additional data about the code not related to WebSQL.
Create new database:
First we want to try and create a new database then add a table to store our data in:
This will alert those users that are on browsers that are not supported that this site will not work for them.
If their browser is supported then a new SQLlite database will be created in their browser for you to save information to.
Load saved data:
If we have saved data then we need to be able to get it out of the database.
A couple of functions at the end to run the required code to display out the data that is saved.
So how do we save data in this database.
My function actually does 2 things.
Should I use this:
My answer is no.
Its nice to play with but it is not supported widly enough.
The ability of searching through the tables is very nice and if this was a standard then I would agree that this would be great to use.