Not sure about that chunk error, but HttpClient does not allow forwards across hosts. The webpage you posted is using a form based login. You should probablly look at the html source and figure out how to do what the browser is doing, as opposed to what the user is doing. (read that twice)

Somthing like this should work:

PostMethod method = new PostMethod "https://login.hotjobs.yahoo.com/display/resume?ct_hft=merge/login";);
NameValuePair[] params = new NameValuePair[]{
new NameValuePair("yesno", "1")
new NameValuePair("username", "xxx"),
new NameValuePair("passwd", "xxx") };
method.addParametersBody(params);

There are also some hidden input fields that you might want to experiment with ... always fun ...

Jandalf.


-------- Original Message --------
Subject: Any example on state(cookie) management across a series of connections?
Date: Mon, 17 Feb 2003 19:37:20 -0800 (PST)
From: Yang Su <[EMAIL PROTECTED]>
Reply-To: "Commons HttpClient Project" <[EMAIL PROTECTED]>, [EMAIL PROTECTED]
To: [EMAIL PROTECTED]



Hi,

I am new here. I am trying to have a simulated http
client whose purpose is to log onto www.hotjobs.com
using username and password, I've written a
program(which I attach) to achieve this, however, the
final step which I try to connect to
"http://my.hotjobs.yahoo.com/display/resume?xxxx";, it
fails with error like this:

java.io.IOException: Bad chunk size: The document has
moved
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to