在JavaScript中调用多个函数以获取用户名/电子邮件地址/密码。当一切都好的时候去goForLogin()并打开一个chrildbrowser。我得到的连接错误(见下图):子浏览器终止
首先我的代码:
function goForLogin(emailaddress, value){
var xmlhttp;
xmlhttp=new XMLHttpRequest();
xmlhttp.open("POST","http://dev.server.com/test/login",true);
xmlhttp.setRequestHeader("Content-type","application/x-www-form-urlencoded");
xmlhttp.send("email=" + emailaddress + "&password=" + value);
xmlhttp.onreadystatechange=function()
{
if (xmlhttp.status==200)
{
value = null;
window.plugins.childBrowser.showWebPage('http://dev.server.com');
} else {
alert("FAILED");
}
}
}
由于未捕获的异常“NSInvalidArgumentException”,原因
*终止应用程序:“应用程序试图把 模态启动控制“。 *第一掷调用堆栈:(0x154012 0x25fce7e 0x478721 0x479777 0x4797b7 0x6a68 0x67471 0x66c5e 0x67039 0x26106b0 0x1198035 0xd7f3f 0xd796f 0xfa734 0xf9f44 0xf9e1b 0x33be7e3 0x33be668 0x38f65c 0x2366 0x2295)的libC++ abi.dylib:终止叫做抛出异常(LLDB)
最新的Cordova和Childbrowser,Xcode 4.4版本。