I am trying to build a gadget that accesses a HTTPS JSON service. I am using
GWT.
The result is* status 400 : Invalid request: unacceptable port*
*
*
GadgetsIo io = IoProvider.get();
ResponseReceivedHandler<JavaScriptObject> handler = new
ResponseReceivedHandler<JavaScriptObject>() {
@Override
public void onResponseReceived(
ResponseReceivedEvent<JavaScriptObject> event) {
Response<JavaScriptObject> response = event.getResponse();
String text = response.getText();
int status = response.getStatusCode();
Window.alert("text : " + text);
Window.alert("status: " + status);
}
};
RequestOptions options = RequestOptions.newInstance();
options.setHeader("Accepts", "application/json");
options.setContentType(com.google.gwt.gadgets.client.io.ContentType.JSON);
options.setMethodType(MethodType.GET);
String url =
"https://firstname%40mydomain:[email protected]/contacts/categories";
io.makeRequestAsJso(url, handler, options);
This code shows the dialog windows with :
*text: Invalid request: unacceptable port
status: 400*
Any ideas ? HTTPS requests not allowed ?
thx !
--
You received this message because you are subscribed to the Google Groups
"iGoogle Developer Forum" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/Google-Gadgets-API?hl=en.