I am trying to construct a simple form with the Play!Framework 2.3.8. Therefore I have created a radiobutton group, which works fine, but how do you pre-select a certain radiobutton?
I did not find anything for this in the documentation:
The same problem exists for checkboxes:
@helper.form(action = routes.Application.submit(), 'id -> "userForm"){
<fieldset>
@helper.inputRadioGroup(
userForm("Geschlecht"),
options = options("Mann"->"Mann","Frau"->"Frau"),
'_label -> "Gender",
'_error -> userForm("Geschlecht").error.map(_.withMessage("select gender"))
)
</fieldset>
Any ideas?
Aucun commentaire:
Enregistrer un commentaire