Cheers guys for the responses。
原来,这是非常挑剔和应用的点点滴滴什么你们给我的工作
现在这里是我的jQuery代码$j.getJSON( "http://localhost:8080/WWTestHarnessWEB/ReadersToolkitFinalController.htm?jsoncallback=?",
{'uID': 1},
function(data, status){ if (status != 'success') { alert("Status is: " + status); } var positiveCount = data.positiveCount;
var negativeCount = data.negativeCount; $j('td[id*="posiiveVoteId"]').html(getCorrectCountString(positiveCount)); $j('td[id*="negativeVoteId"]').html(getCorrectCountString(negativeCount)); });
我的JSON回应如下`ParamsHeadersPostPutResponseCacheHTMLJSON 响应Headersview源 服务器Apache的狼/ 1.1 内容类型的应用程序/ JSON的;字符集= ISO-8859-1 内容语言的en-US Content-Length的80 日期星期三,2010 5月26日十六时38分43秒GMT 请求头文查看源文件 Host localhost:8080 User-Agent Mozilla/5.0(Windows; U; Windows NT 5.1; EN-US; rv:1.9.2.3)Gecko/20100401 Firefox/3.6。3 接受文本/ JavaScript中,应用/ JavaScript的,/ 接受语言EN-US,连接; Q = 0.5 接受编码的gzip,放气 接收字符集ISO-8859-1,utf-8; Q = 0.7,*; q = 0.7 保持活动115 连接保活 内容类型application/x-WWW窗体-urlencoded X-请求-使用XMLHttpRequest 的Referer http://localhost:8080/WWTestHarnessWEB/jsp/ReadersToolkit/Json.jsp 曲奇JSESSIONID = 93FDA3BD0D2450D7FA4BD9A76C388F8A
jsonp1274891923240 ({“positiveCount”:“0”,“negativeCount”:“999”})'
再次感谢 Damien
该URL发生了什么?当然,初始'?'开始查询字符串。 – 2010-05-26 15:53:15