Skip Menu |

This queue is for tickets about the HTML-FillInForm CPAN distribution.

Report information
The Basics
Id: 27376
Status: resolved
Priority: 0/
Queue: HTML-FillInForm

People
Owner: MARKSTOS [...] cpan.org
Requestors: aettinger [...] sdsualumni.org
Cc:
AdminCc:

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



Subject: Add support for ID attribute on form tags (name attribute is deprecated in xhtml)
Add support for <form id="foo"> so we can pass W3C xhtml validation, as <form name="foo"> is deprecated.
Subject: html-fill-in.patch
Only in HTML-FillInForm-1.06-new/: Makefile.old diff -ur HTML-FillInForm-1.06/lib/HTML/FillInForm.pm HTML-FillInForm-1.06-new/lib/HTML/FillInForm.pm --- HTML-FillInForm-1.06/lib/HTML/FillInForm.pm 2005-10-13 13:49:09.000000000 -0700 +++ HTML-FillInForm-1.06-new/lib/HTML/FillInForm.pm 2007-06-01 12:19:16.000000000 -0700 @@ -99,8 +99,8 @@ # set the current form if ($tagname eq 'form') { $self->{object_param_cache} = {}; - if (exists $attr->{'name'}) { - $self->{'current_form'} = $attr->{'name'}; + if (exists $attr->{'name'} || exists $attr->{'id'}) { + $self->{'current_form'} = $attr->{'name'} || $attr->{'id'}; } else { # in case of previous one without </FORM> delete $self->{'current_form'}; diff -ur HTML-FillInForm-1.06/t/11_target.t HTML-FillInForm-1.06-new/t/11_target.t --- HTML-FillInForm-1.06/t/11_target.t 2002-08-29 14:53:37.000000000 -0700 +++ HTML-FillInForm-1.06-new/t/11_target.t 2007-06-01 12:33:19.000000000 -0700 @@ -2,7 +2,7 @@ use strict; use Test; -BEGIN { plan tests => 3 } +BEGIN { plan tests => 8 } use HTML::FillInForm; @@ -16,6 +16,9 @@ <FORM> <INPUT TYPE="TEXT" NAME="foo3" value="nada"> </FORM> +<FORM id="foo4"> +<INPUT TYPE="TEXT" NAME="foo4" value="nada"> +</FORM> EOF ; @@ -23,6 +26,7 @@ foo1 => 'bar1', foo2 => 'bar2', foo3 => 'bar3', + foo4 => 'bar4', ); my $fif = new HTML::FillInForm; @@ -36,3 +40,16 @@ ok($v[0], 'nada'); ok($v[1], 'bar2'); ok($v[2], 'nada'); +ok($v[3], 'nada'); + +my $output2 = $fif->fill( + scalarref => \$form, + fdat => \%fdat, + target => 'foo4', +); + +my @v2 = $output2 =~ m/<input .*?value="(.*?)"/ig; +ok($v2[0], 'nada'); +ok($v2[1], 'nada'); +ok($v2[2], 'nada'); +ok($v2[3], 'bar4');
Subject: Re: [rt.cpan.org #27376] Resolved: Add support for ID attribute on form tags (name attribute is deprecated in xhtml)
Date: Thu, 2 Aug 2007 13:02:34 -0700
To: bug-HTML-FillInForm [...] rt.cpan.org
From: "Anthony Ettinger" <aettinger [...] sdsualumni.org>
I did not see the change in the current source code. On 8/2/07, via RT <bug-HTML-FillInForm@rt.cpan.org> wrote: Show quoted text
> > <URL: http://rt.cpan.org/Ticket/Display.html?id=27376 > > > According to our records, your request has been resolved. If you have any > further questions or concerns, please respond to this message. >
-- Anthony Ettinger Ph: 408-656-2473 var (bonita, farley) = new Dog; farley.barks("very loud"); bonita.barks("at strangers"); http://chovy.dyndns.org/resume.html http://utuxia.com/consulting
Subject: Re: [rt.cpan.org #27376] Resolved: Add support for ID attribute on form tags (name attribute is deprecated in xhtml)
Date: Thu, 02 Aug 2007 16:06:30 -0400
To: bug-HTML-FillInForm [...] rt.cpan.org
From: "Thomas J Mather" <tjmather [...] maxmind.com>
Was just uploaded to CPAN, so should be there in a day or so. Show quoted text
----- Original message ----- From: "aettinger@sdsualumni.org via RT" <bug-HTML-FillInForm@rt.cpan.org> To: undisclosed-recipients: ; Date: Thu, 02 Aug 2007 16:03:05 -0400 Subject: Re: [rt.cpan.org #27376] Resolved: Add support for ID attribute on form tags (name attribute is deprecated in xhtml) Queue: HTML-FillInForm Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=27376 > I did not see the change in the current source code. On 8/2/07, via RT <bug-HTML-FillInForm@rt.cpan.org> wrote:
> > <URL: http://rt.cpan.org/Ticket/Display.html?id=27376 > > > According to our records, your request has been resolved. If you have any > further questions or concerns, please respond to this message. >
-- Anthony Ettinger Ph: 408-656-2473 var (bonita, farley) = new Dog; farley.barks("very loud"); bonita.barks("at strangers"); http://chovy.dyndns.org/resume.html http://utuxia.com/consulting
From: ETTINGER [...] cpan.org
Still don't see it on the cpan.org page for it... http://search.cpan.org/src/TJMATHER/HTML-FillInForm-1.07/lib/HTML/FillInForm.pm look for 'id' On Thu Aug 02 16:06:55 2007, tjmather@maxmind.com wrote: Show quoted text
> Was just uploaded to CPAN, so should be there in a day or so. > > > ----- Original message ----- > From: "aettinger@sdsualumni.org via RT" > <bug-HTML-FillInForm@rt.cpan.org> > To: undisclosed-recipients: ; > Date: Thu, 02 Aug 2007 16:03:05 -0400 > Subject: Re: [rt.cpan.org #27376] Resolved: Add support for ID attribute > on form tags (name attribute is deprecated in xhtml) > > > Queue: HTML-FillInForm > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=27376 > > > I did not see the change in the current source code. > > On 8/2/07, via RT <bug-HTML-FillInForm@rt.cpan.org> wrote:
> > > > <URL: http://rt.cpan.org/Ticket/Display.html?id=27376 > > > > > According to our records, your request has been resolved. If you
have any Show quoted text
> > further questions or concerns, please respond to this message. > >
> > >
Subject: Re: [rt.cpan.org #27376] Add support for ID attribute on form tags (name attribute is deprecated in xhtml)
Date: Tue, 11 Sep 2007 20:25:04 -0400
To: bug-HTML-FillInForm [...] rt.cpan.org
From: "Thomas J Mather" <tjmather [...] maxmind.com>
Looks like you are right - I applied the patch again, and it should be in version 2.00 which is on its way to CPAN. -TJ On Tue, 11 Sep 2007 19:40:03 -0400, "Anthony Ettinger via RT" <bug-HTML-FillInForm@rt.cpan.org> said: Show quoted text
> > Queue: HTML-FillInForm > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=27376 > > > Still don't see it on the cpan.org page for it... > http://search.cpan.org/src/TJMATHER/HTML-FillInForm-1.07/lib/HTML/FillInForm.pm > > look for 'id' > >