[android-developers] Re: Http Response body

2013-01-18 Thread a
It is working as expected now. On Friday, January 18, 2013 11:04:39 AM UTC+2, a wrote: > > There was a problem in my defined handle() method. I was creating a new > HttpResponse for each request instead of using the response passed in the > > public void handle(HttpRequest request, HttpRespons

[android-developers] Re: Http Response body

2013-01-18 Thread a
There was a problem in my defined handle() method. I was creating a new HttpResponse for each request instead of using the response passed in the public void handle(HttpRequest request, HttpResponse response, HttpContext context Thanks! On Thursday, January 17, 2013 12:55:57 PM UTC+2,

[android-developers] Re: Http Response body

2013-01-17 Thread skink
a wrote: > Is the content-type header mandatory? Should it be set to text/plain? > > http://www.w3.org/Protocols/rfc2616/rfc2616.html pskink -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-d

[android-developers] Re: Http Response body

2013-01-17 Thread skink
a wrote: > Thanks for the reply. Ya I m able to see the status and print the status > code in Poster. I am using the same code as in the link, not sure > why HTTP/1.1 200 OK comes even if I dont set the entity in response. I > think it is due to the HttpService constructor, DefaultResponsefactory

[android-developers] Re: Http Response body

2013-01-17 Thread a
Is the content-type header mandatory? Should it be set to text/plain? On Thursday, January 17, 2013 12:37:16 PM UTC+2, a wrote: > > Thanks for the reply. Ya I m able to see the status and print the status > code in Poster. I am using the same code as in the link, not sure > why HTTP/1.1 200 OK c

[android-developers] Re: Http Response body

2013-01-17 Thread a
Thanks for the reply. Ya I m able to see the status and print the status code in Poster. I am using the same code as in the link, not sure why HTTP/1.1 200 OK comes even if I dont set the entity in response. I think it is due to the HttpService constructor, DefaultResponsefactory httpService =

[android-developers] Re: Http Response body

2013-01-17 Thread skink
a wrote: > Hi, > > I am using > link > http://hc.apache.org/httpcomponents-core-ga/httpcore/examples/org/apache/http/examples/ElementalHttpServer.java > to create HTTP server in Android. However in my response I always > get HTTP/1.1 200 OK in the body(though the header has the status code 404 >