Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I browse with localstorage disabled?

A site I'm building uses localstorage with a fallback to php sessions.

How can I test my website in a localstorage free environment without downgrading Firefox, Internet Explorer 8, Chrome or Safari? So I'm probably looking for an add-on for one of these browsers?

I've tried ie7 mode in ie8 - no joy :(

like image 297
Haroldo Avatar asked Jul 06 '11 17:07

Haroldo


2 Answers

For Firefox:

Dom.storage.enabled

The Web Applications 1.0 specification defines a mechanism allowing web pages to store information with a web browser (similar to cookies) called “client-side session and persistent storage.” Although use of session storage is subject to a user’s cookie preferences, this preference allows it to be disabled entirely.

For Chrome:

Chrome/Chromium - disable HTML5 LocalStorage and Databases for all webpages /or ask user

While some resources on the Internet claims that Chrome's cookie blocking does not also block LocalStorage, I just ran a quick test and discovered that it does actually block LocalStorage, (at least in Chrome 12, the current beta version).

For IE:

Internet Explorer

Select “Tools” -> “Internet Options” -> “General” -> check “Delete browsing history on exit”, click on “Delete”, check “Cookies”, click on “Delete” once more and restart your browser afterwards.

Not really sure about Safari but I imagine it is similar to Chrome.

like image 63
Josh Johnson Avatar answered Sep 28 '22 07:09

Josh Johnson


Start Chrome with option/command-line switch:

--disable-local-storage 
like image 25
Mark Avatar answered Sep 28 '22 05:09

Mark