Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var Storage = (function (name) {
- if (supportLocalStorage) {
- var self = window['localStorage'];
- if (!localStorage[name]) {
- localStorage.ApplicationStorage = localStorage[name];
- localStorage.ApplicationStorage.users = localStorage.setItem('ApplicationStorage', 'Users');
- }
- console.log(self);
- document.write(localStorage + '<br>');
- document.write(localStorage.ApplicationStorage);
- } else {
- console.log('Sorry but your browser does not support window.localStorage.');
- }
- function supportLocalStorage () {
- try {
- return 'localStorage' in window && window['localStorage'] !== null;
- } catch (e) {
- return false;
- }
- }
- }(Storage || {}));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement