开发者

Issues with cache manifest and NETWORK section

I'm having an odd issue with the NETWORK section and wildcards. It is my understanding that if I do NETWORK: * and CACHE: X (where X is a list of files), then anything not in the CACHE list will be loaded when I'm online.

When I run Firebug though I can see my cache list is working, however, my requests for Google Maps

<script开发者_开发知识库 type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false">

shows it not loading at all. It's like the NETWORK: * isn't working for the file.


I ran into something similar.

According to various resources, including http://www.html5rocks.com/tutorials/offline/takingappoffline/, cross-domain requests are not possible.

EDIT: And from http://diveintohtml5.ep.io/offline.html

The network section in this cache manifest also has just a single line, a line that contains just a single character (*). This character has special meaning in a network section. It’s called the “online whitelist wildcard flag.” That’s a fancy way of saying that anything that isn’t in the appcache can still be downloaded from the original web address, as long as you have an internet connection.

EDIT 2: While looking into another cache issue I'm seeing I found this other Stack Overflow question: cache google map with HTML5 for iphone offline use error . See in particular the only answer to the question.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜