[html-formfu] Localize value

Stefan catalyst at s.profanter.me
Tue Sep 13 10:41:28 GMT 2011


I'm using Catalyst with FormFu.

Now I want to localize also the values. Localizing labels is already working
with label_loc. But there is no such function for values (like value_loc).


Eg: I hav a select field:


    - type: Select

      name: type

      label_loc: type


To localize the values I use the following code in my Catalyst controller:

               $form->get_element({name => 'type'})->options([





This is working, but is there a better solution??


But this method istn't working if I have multiple radio buttons:


    - type: Radio

      name: breakfast

      label_loc: breakfast

    - type: Radio

      name: breakfast


These two buttons have the same name because they should be a group (Know
already about Radiogroup, but Radiogroup has the strange Border and Title).

How can I set the values on these two radio buttons?

$form->get_all_elements({name => 'breakfast'}) is always returning an empty

I want to set one to Yes and the other to No (localized).


Thanks for your help!!



-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.scsys.co.uk/pipermail/html-formfu/attachments/20110913/98299b44/attachment.htm

More information about the HTML-FormFu mailing list