Apache's HttpClient don't want URL Encoding any ideas how I can bypass?

View: New views
2 Messages — Rating Filter:   Alert me  

Apache's HttpClient don't want URL Encoding any ideas how I can bypass?

by tyweed :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I have an application i'm building that needs to send requests that do not URLEncode characters in the URL. I have tried everything I can think of to bypass the URL Encoding and have had no luck. Is there any idea or work around anyone can offer? I thought about getting the src and altering it but it turned out to be more difficult than I anticipated. I have heard that HTTP Core is an option but i'd rather go that route as last case scenario.

Any ideas any help  would be very appreciated!

Re: Apache's HttpClient don't want URL Encoding any ideas how I can bypass?

by olegk :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

tyweed wrote:
> I have an application i'm building that needs to send requests that do not
> URLEncode characters in the URL. I have tried everything I can think of to
> bypass the URL Encoding and have had no luck. Is there any idea or work
> around anyone can offer? I thought about getting the src and altering it but
> it turned out to be more difficult than I anticipated. I have heard that
> HTTP Core is an option but i'd rather go that route as last case scenario.
>
> Any ideas any help  would be very appreciated!

HttpClient 4.0 relies on the standard java.net.URI class to represent
request URIs. Therefore HttpClient can work with any URI that is
accepted by the java.net.URI parser as a valid one.

If all you want is have to a different formatting for URIs, there are
several extension points one can use to override the standard formatting
routine with a custom one: a custom LineFormatter impl would be one
possibility; another one would be overriding the #getRequestLine()
method of the HttpRequestBase class.

Hope this helps

Oleg

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