On Wed, 2 Jun 2004, bruce wrote:
Youll have to scan their html and possibly javascript etc to see what is going on behind the scenes. they may have two forms on the page, but as andy said they are only really submitting one. Find out which form has the submit button you are clicking, as a web user, and thats probably it. although check for javascript stuff such as onClick or onSubmit events - its possible that all kinds of mojo occurs when you hit the button. you have to duplicate such efforts inside mechanize, be it construction the forms action, or validating variables, or moving info around. matt ok.. so if i can only submit one.. should it matter which one i choose....!! oh.. i found the mech-dump.. thanks!! gotta learn how to type! -bruce -----Original Message----- From: Andy Lester [mailto:[EMAIL PROTECTED] Sent: Wednesday, June 02, 2004 12:28 PM To: Gedanken Cc: bruce; [EMAIL PROTECTED] Subject: Re: :mechanize question.... On Wed, Jun 02, 2004 at 02:25:09PM -0500, Gedanken ([EMAIL PROTECTED]) wrote: > Im jumping in here late so this may be way off but: > > my $agent = WWW::Mechanize->new(); > > $agent->get(someURL); > $agent->form(1) # or form(2) or form(name=>"logonform2") etc > $agent->field("variablename", $myvalue); > $agent->submit(); > > apologies if this super basic summary is way off the mark of what was > asked. I think he's asking how to submit both at once, and you can't. You can only submit one form at a time. That's just how HTTP works. xoa -- gedanken
