Handle disabled localStorage in private mode #2350

Closed
opened 2014-03-03 20:22:41 +00:00 by j · 1 comment
Owner

"QUOTA_EXCEEDED_ERR: DOM Exception 22: An attempt was made to add something to storage that exceeded the quota."

Apparently this is by design. When Safari (OS X or iOS) is in private browsing mode, it appears as though localStorage is available, but trying to call .setItem throws an exception.

http://stackoverflow.com/questions/14555347/html5-localstorage-error-with-safari-quota-exceeded-err-dom-exception-22-an

suggests to call

localStorage.setItem("storage", ""); 
localStorage.removeItem("storage");
"QUOTA_EXCEEDED_ERR: DOM Exception 22: An attempt was made to add something to storage that exceeded the quota." Apparently this is by design. When Safari (OS X or iOS) is in private browsing mode, it appears as though localStorage is available, but trying to call .setItem throws an exception. <http://stackoverflow.com/questions/14555347/html5-localstorage-error-with-safari-quota-exceeded-err-dom-exception-22-an> suggests to call ``` localStorage.setItem("storage", ""); localStorage.removeItem("storage"); ```
j added the
frontend
label 2014-03-03 20:22:41 +00:00
j added this to the 14.01 milestone 2014-03-03 20:22:41 +00:00
rlx was assigned by j 2014-03-03 20:22:41 +00:00
j added the
normal
defect
labels 2014-03-03 20:22:41 +00:00
Author
Owner

In []oxjs,3340:

#!CommitTicketReference repository="" revision="oxjs,3340"
test if localStorage is usable, fixes #2350
In []oxjs,3340: ``` #!CommitTicketReference repository="" revision="oxjs,3340" test if localStorage is usable, fixes #2350 ```
j added the
fixed
label 2014-03-03 20:22:52 +00:00
j closed this issue 2014-03-03 20:22:52 +00:00
Sign in to join this conversation.
No Milestone
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: 0x2620/pandora#2350
No description provided.