1

我正在尝试使用 httpWebRequest 调用 web 服务,但我得到的响应总是 null JSON。

var con = $.net.http.getConnection("http://api.geonames.org/citiesJSON?north=44.1&south=-9.9&east=-22.4&west=55.2&lang=de&username=demo");
con.setProxy("proxy", 8080); 
var resp = con.request("GET", "/Service1.html");

//resp here is always null 

我得到的输出是这样的:

 {}

真的不知道我哪里错了。

如果您对此有所了解,请帮助我。

4

0 回答 0