質問

I have a webapp that works offline. I would like to set an expiration date to the cache so if the user does not reconnect to the server for a certain amount of time the cache is cleared and the user cannot use the application anymore.

I think the timer part is easy but I cannot find any way to delete programmatically the cache when I'm offline. I had found the way only when I'm online

役に立ちましたか?

解決

There is currently no way to programmatically delete the appcache, you have to respond to a request for the manifest with a 404. There is some interest at the W3C in extending the current offline capabilities, you might consider getting your use case added to the list.

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top