HTML5 Offline Storage with Android Browsers

2019-04-09 18:16发布

问题:

I am investigating using an Android device for a website that needs to be usable offline. I have not been able to find much information on how the Android browser handles HTML5's localStorage and WebSQL. Does anyone know the size limit for these? Are they changeable (I know mobile Safari allows WebSQL to store up to 50mb if requested).

Additionally, any good resources on the Android browser? I haven't been able to find anything good.

Thanks.

回答1:

There was a talk about client side persistent storage at this years JSConf.eu in Berlin. Some of the slides also touch the Android 2.1/2.2 browser maybe they can give you some hints:

http://www.slideshare.net/jensarps/the-hitchhikers-guide-to-client-side-persistent-storage



回答2:

Check out using jquery mobile or sencha as your framework for your online/offline app. Using a cache manifest isn't terribly difficult there are a bunch of tutorials out there:

http://www.nils-dehl.de/2010/06/how-to-make-a-sencha-touch-app-offline-usable-with-the-html5-cache-manifest/