hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dimitrios Christodoulakis" <dimi....@gmail.com>
Subject difference between request headers and request params
Date Fri, 23 May 2008 21:03:09 GMT
Hello, I am a new user of HTTPClient and trying to learn how to use
it. I have read the relevant primer and user guide but I am not sure
what is the difference between headers and parameters. Do they have
the same functionality for GET and POST requests? I mean does the
server processes and responds differently to headers or parameters?

I am trying to set request headers with
addRequestHeader("MyHeaderName", "MyHeaderValue"); and then after
executing the method I print the headers like:

Header[] reqheaders = authget.getRequestHeaders();
           for (int i=1; i<reqheaders.length; i++) {
           System.out.println(reqheaders[i].getName().toString() +" = "+

But no headers are displayed.

Thanks for helping

To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
For additional commands, e-mail: httpclient-users-help@hc.apache.org

View raw message