Load content from localStorage


/ Published in: jQuery
Save to your folder(s)

Simple way to load saved content from localStorage


Copy this code and paste it in your HTML
  1. if (localStorage["myKey"] != null) {
  2. var storagename = JSON.parse(localStorage["myKey"]);
  3. $(".content").html(storagename);
  4. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.