Long story short: I'm working on an Android App that will let
developers have access to their Google Code projects in a mobile
friendly package. I'm trying to get commenting and creating issues
from the Android device working, but I haven't found a way to do so.
I keep getting different errors, 403, 501. I'm frankly tired,
exhausted and out of ideas.
My relevant piece of code:
String xml =
"<?xml version='1.0' encoding='UTF-8'?>" +
"<entry xmlns='http://www.w3.org/2005/Atom' " +
"xmlns:issues='http://schemas.google.com/projecthosting/issues/
2009'>"+
"<content type='html'>"+((EditText)
textEntryView.findViewById(R.id.comment_edit)).getText().toString()+"</
content>"+
"</entry>";
StringEntity se = new StringEntity(xml,"UTF-8");
se.setContentType("application/atom+xml");
HttpPost postRequest = new HttpPost("http://code.google.com/feeds/
issues/p/"+projName+"/issues/"+issueId+"/comments/full");
postRequest.setHeader("Authorization", "GoogleLogin auth=" + auth);
postRequest.addHeader("GData-Version", "3.0");
postRequest.addHeader("If-Match", "*");
postRequest.addHeader("Content-Type","application/atom+xml");
postRequest.setEntity(se);
HttpResponse response = new DefaultHttpClient().execute(postRequest);
//Thanks very much for your help!
--
You received this message because you are subscribed to the Google Groups
"Project Hosting on Google Code" 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-code-hosting?hl=en.