Reputation: 1638
The URL is http://www.iwi.hs-karlsruhe.de/Intranetaccess/REST/courseofstudies/all.json
I can view the JSON file in my browser, but when I tried to get it in GWT, the result is empty. The alert in the following code is empty.
RequestBuilder rb = new RequestBuilder(RequestBuilder.GET, jsonURL);
rb.setCallback(new RequestCallback() {
@Override
public void onResponseReceived(Request request,
Response response) {
Window.alert(response.getText());
}
@Override
public void onError(Request request, Throwable exception) {
System.out.println("onError");
}
});
rb.send();
Upvotes: 0
Views: 59
Reputation: 16060
I am pretty sure it is all about the same-origin policy.
Empty response text and a HTTP-code 0.
You cannot connect to that URL unless you are:
Upvotes: 2