I heartily agree.  I've been using HttpClient off and on this past year
and have fortunately been able to use it quite effectively, and I know
to check for Javascript that sets necessary hidden variables as the form
is being submitted, etc.  I convinced myself that I was dealing with a
new problem that defied all the tiny bit of knowledge I have on web
standards on HTTP requests, but I found out it has to do with redirects
and cookies instead.  

There's no way to set it to automatically follow redirects and so avoid
the following message, is there?  Here it is:
-------
Sep 11, 2004 3:28:03 AM org.apache.commons.httpclient.HttpMethodBase
processRedirectResponse

INFO: Redirect requested but followRedirects is disabled
-------

Also, in the case of an error saying "Cookie rejected" due to an
"Illegal path attribute", can we get it to accept it anyway?  Do we have
to write our own subclass like what is mentioned here:

http://www.mail-archive.com/[EMAIL PROTECTED]/msg06800.html









----- Original message -----
From: "Oleg Kalnichevski" <[EMAIL PROTECTED]>
To: "Jakarta Commons Users List" <[EMAIL PROTECTED]>
Date: Sat, 11 Sep 2004 01:03:29 +0200
Subject: Re: HttpClient:  submit via input of type="image"

Stephen,

When it comes to computers, things rarely happen by Lord Almighty's
will. Just carefully examine the page source in the browser. There must
be a FORM in the HTML source that most likely gets triggered by a
javascript event. Once you know what action needs to be executed and
what parameters are expected, it should be pretty trivial to implement
the same using HttpClient

Hope this helps a little

Oleg


On Fri, 2004-09-10 at 23:38, Stephen Charles Huey wrote:
> Hey, I'm a major aficionado of HttpClient, but I'm stumped.  How do you
> submit a form that can't really be submitted without either hitting the
> Enter key while in an input of type="text" or clicking on an input of
> type="image"?  In other words, say you have a JSX page where there are
> event handlers on the server checking to see whether the Enter key was
> pressed or an image was clicked (there's no basic submit button).  Is it
> possible to use HttpClient or write something to work with it that will
> send a request up to the server and trick the server into thinking that
> one of these events occurred in the web browser?  Or is this just too
> hairy for a lowly intermediate level coder like myself?  :)  
> 
> I like these cool form controls, but I guess they can be a pain
> sometimes.  
> 
> Thanks,
> Stephen
> 
> ---------------------------------------------------------------------
> 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]


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

Reply via email to