commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Allistair Crossley" <a.cross...@obvious.uk.com>
Subject HttpClient PostMethod To IP + Port + Path Error
Date Thu, 25 Apr 2002 10:35:59 GMT
Hi,

I need to request a URL like this;

http://123.456.78.9:8026/page.asp

The request works fine in a web browser.

I use HttpClient to do this as follows;

PostMethod postMethod = new PostMethod("/page.asp");

HttpClient httpClient = new HttpClient();
httpClient.startSession("123.456.78.9", 8026);
httpClient.executeMethod(postMethod);
httpClient.endSession();

System.out.println(postMethod.getResponseBodyAsString());

I get a NoRouteToHostException for this which I find strange.

Help appreciated,

Ali


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


Mime
View raw message