[Catalyst] C::C::FormBuilder and custom template

Juan Camacho jc5826 at gmail.com
Mon Dec 11 15:23:34 GMT 2006


On 12/11/06, Goetz Bock <bock+catalyst at blacknet.de> wrote:
>
> Dear list,
>
> as I'm not totaly sure wether to try the catalyst or the formbuilder ML,
> I choose the catalyst ML, as it's probably a problem with (the docs of)
> C::C::FormBuilder.
>
> I'm using the SVN version of C::C::FormBuilder, revision 5783.
>
> When I build my TT2 Template accourding to the docs, I'm unable to
> submit it, as the hidden "_submitted" field is not generated and
> form->submitted() always is false.
>
> When I use form.render, everythign is fine.
>
> What should I do:
> - remove the if ( form->submitted() ) test from my controller
> - manualy add a hidden _submitted field, but it would always be 1

Under TT2 the [% form.start %] will include the statetags.   The [%
form.statetags %] doesn't seem to work, and the C::C::FormBuilder docs
should not mention it.  This seems to be the fault with
CGI::FormBuilder -- the best thing to do is to get the exact same
template working outside of Catalyst using
CGI::FormBuilder->new(source => 'foo', template => 'baz, ...) directly
to see if there is something that is inconsistent in the Catalyst
wrapper.



More information about the Catalyst mailing list