On 3/23/2011 5:19 AM, Carl Franks fireartist-at-gmail.com |FormFu Mailing List/Allow to
home| wrote:
See "container_attributes"
http://search.cpan.org/~cfranks/HTML-FormFu-0.08002/lib/HTML/FormFu/Element/_Field.pm#container_attributes
That reads in full, "Arguments added to the field's container.". It's shorter than the
url that you pointed to it with!
It's not really clear that the "attributes" you are referring to are HTML attributes on
the tag; it seems like some kind of property or parameter used by the code itself.
I'd personally recommend using CSS to rearrange them, but if you want
to change the markup - single_reverse is the correct way.
I've just tested it, and it does work - did you check the actual
markup? Maybe your CSS was making it look like nothing had changed.
I've just committed a new test to github, so you can see how I tested
it - see the files:
t/elements/checkbox_reverse.t
t/elements/checkbox_reverse.yml
Ah, I just used the keyword on a line by itself, and did not follow it with a
'1'.
Using CSS, how would you reverse them?
* On a related note, how do I make the checkbox initially checked when the
form is displayed with no data? The value is already 1, and I guess that's
what it would be if it was set. What I want to do is display a text area,
and under that a submit button on the left, and a checkbox with "CC me" on
the right, on the same level as the button.
$field->default(1);
Thanks. I seem to have stopped reading when I saw «For most fields, "value"
<http://search.cpan.org/%7Ecfranks/HTML-FormFu-0.08002/lib/HTML/FormFu/Element/_Field.pm#value>
is an alias for "default"
<http://search.cpan.org/%7Ecfranks/HTML-FormFu-0.08002/lib/HTML/FormFu/Element/_Field.pm#default>.»,
and looked in the Checkbox class itself for details on what it does differently. The use
for Checkbox is documented (only) in Field.
Hope this helps,
Carl
Indeed! That fixes everything I was hung up on. Thank you for your
comprehensive reply.
_______________________________________________
HTML-FormFu mailing list
HTML-FormFu@lists.scsys.co.uk
http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/html-formfu