hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Roland Weber <ossf...@dubioso.net>
Subject Re: Using Post-method but getting "URI to long"?
Date Wed, 18 Jul 2007 14:34:36 GMT
Hello Timo,

> request failed: URI too long (longer than 8190)
> 
> Google now tells me, that this only happens using the "GET" method,
> because with GET the length of an URL is limited.

If you do it right, it happens only with the GET method.

>       HttpMethod method = new PostMethod(url);
>       method.setQueryString(urlParams);

If you want to post your data in the message body, don't
add it to the URL query string. Add it as parameters.

cheers,
  Roland


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


Mime
View raw message