Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the WWW-Mechanize CPAN distribution.

Report information
The Basics
Id: 55480
Status: resolved
Priority: 0/
Queue: WWW-Mechanize

People
Owner: Nobody in particular
Requestors: PETEK [...] cpan.org (weekly)
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: (no value)
Fixed in: (no value)



Subject: HTML::Form::ImageInput does not include value="" on click [patch]
When telling LWP to click on an input of type "image", the x and y coordinates are transmitted to the server. However, if there is a value="foo" attribute present, that value is not passed along. Attached is a suggested patch to HTML::Form which includes a value, if present, as part of the request.
Subject: Form.patch
--- /usr/lib/perl5/site_perl/5.8.8/HTML/Form.pm 2009-07-07 14:29:33.000000000 -0500 +++ Form.pm 2010-03-11 14:11:50.000000000 -0600 @@ -1401,7 +1401,15 @@ return if $self->{disabled}; my $name = $self->{name}; $name = (defined($name) && length($name)) ? "$name." : ""; - return ("${name}x" => $clicked->[0], + + my %more = (); + if ($name ne '' && defined($self->{value})) { + $more{ $self->{name} } = $self->{value}; + } + + + return (%more, + "${name}x" => $clicked->[0], "${name}y" => $clicked->[1] ); }
migrated queue: libwww-perl -> WWW-Mechanize