开发者

How to cache a big XML file for use in Mobile web app?

I've written a cache manifest file for a big XML file I'm reading data from. I want the app to be accessi开发者_StackOverflow社区ble offline and to respond quickly. This XML file weighs some 5MB, it's essentially a whole database table.

The cache manifest file reads:

CACHE MANIFEST

/ipad/doctors.xml

I realize I should indicate all files I'm using but now for the purpose of development it's just doctors.xml.

It seems however that every time I reload the page the file keeps getting downloaded from the server. I'm not sure if cache.manifest actually tells the browser to reload the page as long as we're online, otherwise redownload everything. I haven't tried it offline.

What seems to be the problem? Is it even possible to cache such a big file on a mobile device web browser?

Thanks!


I think that having just

CACHE MANIFEST

/ipad/doctors.xml

is for Offline cache

I believe that, if you want the cache to be taken into account when on-line as well, the syntax is

CACHE MANIFEST

CACHE:
/ipad/doctors.xml

Did you try this ?

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜