HTML5 Application Cache manifest file location on hard drive

浪尽此生 提交于 2019-12-12 02:53:34

问题


I have a site which uses HTML5 App Cache and I'm having trouble determining why the cache update started. I haven't made changes or added/removed files.

The manifest file is generated dynamically and includes all files from the app's folder, except a few which should not be cached. I would like to check the cached manifest file to see what is the difference between it and the current version.

How do the browsers store the manifest file so they are able determine when it has changed and when should the cache update kick in ?

Can this file be found somewhere on the hard drive in the browser's cache folder ?


回答1:


Yes they have to. How it should work otherwise? Stored in RAM it would be lost after reboot and stored only in web could not lead to an offline app.

But where they store them and if they are encrypted is another question. In Firefox: C:\Users\brach\AppData\Local\Mozilla\Firefox\Profiles\xxxxx.default\OfflineCache\0\9\77546B5B27E111-0

The content of that file is

    CACHE MANIFEST

    CACHE:
    style.css
    script.js
    index.htm

So that's a manifest how we know it. But for other browsers you have to explore it by yourself... ;)


  • In Firefox you can easily find it out entering about:cache as URL and look in Offline cache device section.
  • In chrome you can enter chrome://appcache-internals as URL and let you show the content of any cached file including the manifest directly in the browser.


来源:https://stackoverflow.com/questions/8968862/html5-application-cache-manifest-file-location-on-hard-drive

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!