嗨,我收到了错误消息
当我调用 HTML 文件时,我正在使用这种方法
url:'http://abcccc/'+data.userId,
success:function(userInfo){
$.cookie('iTouchUser', JSON.stringify(userInfo));
// window.location='list.html'; (i've try this method also)
window.location.replace('file:///android_asset/www/list.html');
我收到的错误消息是
DroidGap(991): DroidGap.loadUrl(file:///android_asset/www/list.html)
DroidGap(991): DroidGap: url=file:///android_asset/www/list.html baseUrl=file:///android_asset/www/
PluginManager(991): init()
CordovaLog(991): JSCallback Server Closed: Stopping callbacks.
CordovaLog(991): file:///android_asset/www/cordova-1.8.0.js: Line 3708 : JSCallback Server Closed: Stopping callbacks.
Web Console(991): JSCallback Server Closed: Stopping callbacks. at file:///android_asset/www/cordova-1.8.0.js:3708
我已经在 cordova-1.8.0.js:3708 中检查过了
// If server is stopping
else if (xmlhttp.status === 503) {
console.log("JSCallback Server Closed: Stopping callbacks.");
}
谁知道如何解决这个错误
最佳答案
对于 Android,请尝试使用 navigator.app.loadUrl('url')
而不是 window.location
关于javascript - JSCallback Server Closed : Stopping callbacks如何解决,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11014732/