Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <script>
- // Check browser support
- if (typeof(Storage) !== "undefined") {
- // Store
- localStorage.setItem("userID", post);
- // Retrieve
- document.getElementById("result").innerHTML = localStorage.getItem("userID");
- } else {
- document.getElementById("result").innerHTML = "Sorry, your browser does not support Web Storage...";
- }
- </script>
Add Comment
Please, Sign In to add comment