小编use*_*438的帖子

在使用HTML5的appcache功能时如何允许json请求?

当我向运行jquery mobile的webapp添加appcache时,所有从我的服务器stoppet请求json文件的ajax调用工作.我的清单文件如下所示:

CACHE MANIFEST

CACHE:

index.html
scripts/jquery-1.7.1.min.js scripts/jquery.flot.min.js
scripts/jquery.flot.threshold.min.js
scripts/jquery.mobile-1.0.1.min.js
styles/jquery.mobile-1.0.1.min.css
styles/touchStyles.css
styles/styles.css

NETWORK: 

index.appcache
dataFetchAndDraw.js
initJson
Run Code Online (Sandbox Code Playgroud)

其中initJson是其中一个无效的调用.我试图输入完整的地址(aaa:bbb:ccc:ddd:6565/initJson)也没有成功.

在我的.htaccess文件中,我只有这一行:

AddType text/cache-manifest .manifest
Run Code Online (Sandbox Code Playgroud)

json html5-appcache

6
推荐指数
2
解决办法
3073
查看次数

标签 统计

html5-appcache ×1

json ×1