HTML5 localStorage 本地存储文件

HTML5 的localStorage用的是SQLite数据库存储数据的,默认其中只有一张名为itemTable的表;

表中有两个字段: key和value,用来存储键值对



至于本地存储文件的位置Google了好久才找到,直接引用stackoverflow的片段:

http://stackoverflow.com/questions/8634058/where-the-sessionstorage-and-localstorage-stored/15711210#15711210


Firefox

Firefox stores localstorage in webappsstore.sqlite file in the profile folder.

Firefox (Windows XP):

C:\Documents and Settings\<Windows login/user name>\Application Data\Mozilla\Firefox\Profiles\<profile folder>\webappsstore.sqlite

Firefox (Windows Vista and above):

C:\Users\<Windows login/user name>\AppData\Roaming\Mozilla\Firefox\Profiles\<profile folder>\webappsstore.sqlite

or:

%APPDATA%\Mozilla\Firefox\Profiles\<profile folder>\webappsstore.sqlite

Firefox on linux:

~/.mozilla/firefox/<profile folder>/webappsstore.sqlite

Firefox on mac:

~/Library/Application Support/Firefox/Profiles/<profile folder>/webappsstore.sqlite

or:

~/Library/Mozilla/Firefox/Profiles/<profile folder>/webappsstore.sqlite

Chrome

Chrome stores in separate files inside the Local Storage directory.

Chrome on windows:

%LocalAppData%\Google\Chrome\User Data\Default\Local Storage\

Chrome on linux:

~/.config/google-chrome/Default/Local Storage/

Chrome on mac:

~/Library/Application Support/Google/Chrome/<Profile>/Local Storage/

commonly:

~/Library/Application Support/Google/Chrome/Default/Local Storage/

Internet explorer:

I am a bit unsure, but think this will do the trick

%userprofile%\AppData\LocalLow\Microsoft\Internet Explorer\DOMStorage

Opera

As said by OammieR:

C:\Users\Administrator\AppData\Roaming\Opera\Opera\sessions\autosave.win

or as said by Kevin Hakanson:

C:\Users\Administrator\AppData\Local\Opera\Opera\pstorage\

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值