I posted this originally during YAPC. I trust your hangovers are
better now.



I'm sure you remember me wibbling about getting checkbox groups to
work. Well, this is fine:

  [% q.checkbox_group({ Name => 'keyword_id'
               Values =>  keyword.keys.sort
               Default => keywords
               Labels => keyword 
                } ).join("\n") %]

Now, we decided that unpicking them on form entry required some Real
Code:

sub checkbox {
  my $self = shift ;
  my $check = shift || return undef ;

  my $r = $self->{_request} ;
  my @stuph = $r->param('keyword_id') ;
#  warn Dumper(\@stuph) ;
  return \@stuph ;
}


This works but only for a GET method! Using a POST (necessary for body
text stuff) fails. Any clues?

Ta,

Dave

_______________________________________________
templates mailing list
[EMAIL PROTECTED]
http://www.template-toolkit.org/mailman/listinfo/templates

Reply via email to