You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by Saminda Abeyruwan <sa...@opensource.lk> on 2005/09/30 06:16:58 UTC

How to select btw httpverions in commons-httpclient-3.0-rc3

Hi devs,

I have found that some of the methods which switches betweed http 
version being depricated. I'm using commons-httpclient-3.0-rc3 and 
codecs to do my work. Seems couldn't find a way to select the transport 
verion from this newest version. It always gives HTTP1.1. That's pretty 
cool, but some politics says they need HTTP1.0. Hmmm..If it's possible 
could someone please aid me on how to switch between version.

Thanks

Saminda


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


Re: How to select btw httpverions in commons-httpclient-3.0-rc3

Posted by Saminda Abeyruwan <sa...@opensource.lk>.
Oleg,

Thanks for the quick reply.

Saminda

Oleg Kalnichevski wrote:

>On Fri, Sep 30, 2005 at 10:16:58AM +0600, Saminda Abeyruwan wrote:
>  
>
>>Hi devs,
>>
>>I have found that some of the methods which switches betweed http 
>>version being depricated. I'm using commons-httpclient-3.0-rc3 and 
>>codecs to do my work. Seems couldn't find a way to select the transport 
>>verion from this newest version. It always gives HTTP1.1. That's pretty 
>>cool, but some politics says they need HTTP1.0. Hmmm..If it's possible 
>>could someone please aid me on how to switch between version.
>>
>>Thanks
>>
>>Saminda
>>
>>    
>>
>
>This would do the trick
>
>HttpClient httpagent = new HttpClient();
>httpagent.getParams().setVersion(HttpVersion.HTTP_1_0);
>
>For more details see
>http://jakarta.apache.org/commons/httpclient/preference-api.html
>
>Oleg
>		
>
>  
>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: httpclient-dev-unsubscribe@jakarta.apache.org
>>For additional commands, e-mail: httpclient-dev-help@jakarta.apache.org
>>
>>
>>    
>>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: httpclient-dev-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: httpclient-dev-help@jakarta.apache.org
>
>
>  
>


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


Re: How to select btw httpverions in commons-httpclient-3.0-rc3

Posted by Oleg Kalnichevski <ol...@apache.org>.
On Fri, Sep 30, 2005 at 10:16:58AM +0600, Saminda Abeyruwan wrote:
> Hi devs,
> 
> I have found that some of the methods which switches betweed http 
> version being depricated. I'm using commons-httpclient-3.0-rc3 and 
> codecs to do my work. Seems couldn't find a way to select the transport 
> verion from this newest version. It always gives HTTP1.1. That's pretty 
> cool, but some politics says they need HTTP1.0. Hmmm..If it's possible 
> could someone please aid me on how to switch between version.
> 
> Thanks
> 
> Saminda
> 

This would do the trick

HttpClient httpagent = new HttpClient();
httpagent.getParams().setVersion(HttpVersion.HTTP_1_0);

For more details see
http://jakarta.apache.org/commons/httpclient/preference-api.html

Oleg
		

> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: httpclient-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: httpclient-dev-help@jakarta.apache.org
> 
> 

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