How to support multiple custom cache manifest for offline use, on a user by user basis? [duplicate]

妖精的绣舞 提交于 2019-12-10 21:47:32

问题


Possible Duplicate:
HTML5 Cache — Is it possible to have several distinct caches for a single URL?

My app uses the concept of Projects, each Project has multiple support files (primarily image files and pdf's) that need to be made available offline. I want to use HTML5 cache-manifest to accomplish this.

If I include all the support files for all the projects in the cache-manifest it would be massive and not feasible. (I.e. there wouldn't be enough room on the mobile devices and it would be complete overkill, users only need the support files of the projects they are assigned to)

User's are assigned to Projects, so ideally I could have a custom cache-manifest file for each user that contains the support files needed for the projects that user is assigned to.

How can I accomplish this? Is there a way to assign a different cache-manifest after the browser has loaded the initial page?

If not, what is another way to accomplish this functionality?


回答1:


This question: HTML5 Cache — Is it possible to have several distinct caches for a single URL? is very similar and proposes a solution using iframes. I haven't tried it but it came up in my search next to this question. Good luck!



来源:https://stackoverflow.com/questions/7807563/how-to-support-multiple-custom-cache-manifest-for-offline-use-on-a-user-by-user

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