HTML Data storage: (Mobile, PC-side):
History:
Previous storage methods: Cookies: Small storage (4KB, stored on the server) network shutdown data disappeared;
Now: Local data storage:
1. Localstorage: Advantages: No time limit data will be saved, unless manually deleted; (common)
Writing:
Localstorage.setitem ("name", "Zhao"); Assign the Zhao to name
Adimin.value = Localstorage.setitem ("Adimin");
// Adimin.value (i.e. localstorage.setitem ("Adimin") and save = localstorage.setitem ("Adimin", Adimin.value); &NBSP
pass Words.value = Localstorage.setitem ("passwords");
Assign the Passwords.value (that is, the password to be entered) to Localstorage.setitem ("passwords") and save = Localstorage.setitem ("Passwords", pass Words.value);
2.sessionStorage: Insufficient: Automatic deletion of saved data site closed data emptying
Writing:
Admin.value = Sessionstorage.admin;
Case CSS:
Show:
When we enter the value click on the next automatic login (as to save the data, do a little flaw, save data);
Click Send login; The data will be emptied;
When we send it, we enter the value again in the input box
Data saved successfully!
HTML5 Data storage