Android浏览器会忽略移动设备上的缓存清单(银河S3) [英] Android browser ignores cache manifest on mobile device (Galaxy S3)

查看:88
本文介绍了Android浏览器会忽略移动设备上的缓存清单(银河S3)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在我使用的是缓存清单的Web应用程序。
总之,当我修改缓存清单,EXCEPT的Andr​​oid(银河S3)所有浏览器将获取新的文件,并更新缓存。
它的工作原理就像有望与iPhone和桌面版Chrome / Safari浏览器上。即使我下载Chrome到S3,它工作正常。

I have a web application in which I am using a cache manifest. In short, when I modify the cache manifest, all browsers EXCEPT Android (Galaxy S3) will fetch the new files and update the cache. It works just as expected with Iphone and desktop Chrome/Safari browsers. Even if I download Chrome onto the S3, it works fine.

它几乎似乎该设备甚至缓存清单文件,以便它似乎没有改变。我不知道。

It almost seems that the device is even caching the manifest file so that it appears to not have changed. I'm not sure.

没有人有任何想法,为什么这可能发生?或编程的方式来得到这个工作?

Does anyone have any ideas as to why this may be happening ? or a programmatic way to get this to work ?

在此先感谢!

下面是code(cache.appcache)。清单文件位于我的项目的根目录:

Here is the code (cache.appcache). the manifest file lies in the root of my project:

CACHE MANIFEST
# b749e3a4d167d44f1404d777732b5bjkjkf05207c59ab7ca
index.html
app.js

FALLBACK:


NETWORK:
*

我的index.htmlHTML标签如下所示:

My index.html 'html' tag looks like this:

<!DOCTYPE HTML>
<html manifest="cache.appcache" lang="en-US">

这就是它的清单。在我的JS code,我只是有一个检测到新的清单时,该侦听UPDATEREADY事件的事件。
在所有的浏览器,当我改变该事件的触发清单的'版本',而新的code是牵强。在默认的Andr​​oid浏览器,它不修改清单后火了,我可以看到,新的code没有被抓取。

That's it for the manifest. In my JS code, I just have an an event which listens for the 'updateready' event when a new manifest is detected. In all browsers, that event fires when i change the 'version' of the manifest, and the new code is fetched. In the default android browser, it does not fire after modifying the manifest, and I can see that the new code is not being fetched.

推荐答案

好吧只是踢我从'cache.appCache'到'cache.manifest改变了清单文件的名称和它的工作!很奇怪考虑到不应该的问题。 :0

Well just for kicks I changed the name of the manifest file from 'cache.appCache' to 'cache.manifest' and it worked ! Very odd considering that shouldn't matter . :0

这篇关于Android浏览器会忽略移动设备上的缓存清单(银河S3)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆