application-cache

Programmatically clear HTML 5 application cache in log-on/log-off scenario

独自空忆成欢 提交于 2019-12-10 17:29:44
问题 HTML 5 offline logic is encapsulated in window.applicationCache object. However it looks like it's not possible to programmatically clear cache data, for example, when user logs off from the system. Is there any other way to clear HTML 5 application cache, except for generating empty manifest file? 回答1: Setting aside the specifics of the HTML5 appcache, clearing a browser's cache programmatically has never been possible (beyond certain ActiveX controls for that browser) so I suspect you may

Clearing the Cache on OS Versions above Marshmallow

孤者浪人 提交于 2019-12-10 14:56:49
问题 I want to make an Android App which will clean the cache of other apps. I have figured out how to do that for Android Version below Marshmallow. This is what I am using for Android Honeycom and above: if (isExternalStorageWritable()) { final File externalDataDirectory = new File(Environment .getExternalStorageDirectory().getAbsolutePath(), "/Android/data"); final String externalCachePath = externalDataDirectory.getAbsolutePath() + "/%s/cache"; if (externalDataDirectory.isDirectory()) { final

AppCache Manifest Error

柔情痞子 提交于 2019-12-10 01:13:45
问题 Edit : I had to remove some links. My manifest page seems to be causing errors on my web page. When you first go to the page everything appears to cache successfully, but upon refresh it fails to get files that exist. I made a quick test page to check out, here. Here is my manifest file. This is a VERY dynamic site by php & javascript, I haven't got too much into appcache with those factors, so I'm unsure if the issue has to do with the fact that so much content has to be conditionally set in

Pre-populate HTML5 offline appcache for a UIWebView in an iOS application

泄露秘密 提交于 2019-12-10 01:04:36
问题 Is it possible to create a UIWebView that has an HTML5 offline appcache pre-populated so that it will work offline even if it is the first time the user is accessing the UIWebView? If so, how? I know I can achieve this through other mechanisms, but the above is my first choice. And I'm just plain curious if it's possible. I'm seeing nothing about it in the documentation. 回答1: I think this may reduce to a question of whether you can programmatically write to the UIWebView's cache file (which

How to clear Application cache (HTML5 feature) using JavaScript?

为君一笑 提交于 2019-12-05 09:39:43
Our Web-Application uses Application cache (cache manifest) to restore HTML page and resources in off-line mode. HTML-pages have sessionIDs as params in URI. So, after each logout and login action new HTML-pages are saved to application cache because sessionId was changed in URI. After some weeks working with application some browsers start work slower. And size of Application cache (tested on FF 3.6+) is about 200Mb! After each logout we clear LocalStorage of browser,but how to clear resources from Application storage? The problem with the application cache taking up so much space is that you

Pre-populate HTML5 offline appcache for a UIWebView in an iOS application

浪尽此生 提交于 2019-12-04 23:59:21
Is it possible to create a UIWebView that has an HTML5 offline appcache pre-populated so that it will work offline even if it is the first time the user is accessing the UIWebView? If so, how? I know I can achieve this through other mechanisms, but the above is my first choice. And I'm just plain curious if it's possible. I'm seeing nothing about it in the documentation. I think this may reduce to a question of whether you can programmatically write to the UIWebView's cache file (which is to say, whether the UIWebView cache resides within your app's sandbox) – if you can't, then game over. If

AppCache Manifest Error

末鹿安然 提交于 2019-12-04 23:57:47
Edit : I had to remove some links. My manifest page seems to be causing errors on my web page. When you first go to the page everything appears to cache successfully, but upon refresh it fails to get files that exist. I made a quick test page to check out, here. Here is my manifest file. This is a VERY dynamic site by php & javascript, I haven't got too much into appcache with those factors, so I'm unsure if the issue has to do with the fact that so much content has to be conditionally set in. Any help would be greatly appreciated. NOTE: Java-Console will be needed (best used in Chrome).

Cache Manifest: What is the prefer-online setting?

流过昼夜 提交于 2019-12-04 16:21:07
问题 I've been looking for a way to cache pages for use only when the user is offline, otherwise download the pages normally. However, once a cache manifest is detected, the browser will only load from those cached pages. My search landed me on http://whatwg.org. The section about Writing Cache Manifests caught my eye. Here's an excerpt: A section header Section headers change the current section. There are four possible section headers: CACHE: Switches to the explicit section. FALLBACK: Switches

Chrome reporting html5 cache manifest mime type incorrectly

半腔热情 提交于 2019-12-04 10:57:54
I'm trying to set up a cache manifest for a site and am having little luck. A demo page is here: http://www.matthewlehner.ca The HTML I'm using has this structure: <!DOCTYPE html> <html manifest="manifest.appcache"> </html> .htaccess in the root folder has the following entry: AddType text/cache-manifest appcache AddType text/cache-manifest .appcache Response from `curl -I http://www.matthewlehner.ca/manifest.appcache ' HTTP/1.1 200 OK Date: Sun, 11 Sep 2011 00:04:30 GMT Server: Apache Last-Modified: Sat, 10 Sep 2011 07:53:30 GMT ETag: "18a84003-32-4ac9196f95280" Accept-Ranges: bytes Content

iPad Home Screen App refreshes on every open

天涯浪子 提交于 2019-12-03 08:52:25
问题 I'm writing a web app for the iPad using HTML5 and SenchaTouch. The app uses cache manifest to function offline. Once it has been added in the home screen and opened without Safari, it will refresh itself every time it is opened, even if just navigating to the home screen and back. The desired behavior is to leave the app, do something else, and then come back to the app with everything untouched. An example of a similar app that displays the same (undesired) behavior can be found here: http: