I have a JSP page with a set number of questions and a Form object with a HashMap of question names and values.
When I submit the form, some of the values go through (all of the checkboxes), others (all radio inputs) are left blank.
Radio (jsp):
<html:radio property="<%=\"boolean(\" + questionBase + \"V\" + respLabel + \")\"%>" styleClass="pepperoni1" value="1" >Yes</html:radio>
<html:radio property="<%=\"boolean(\" + questionBase + \"V\" + respLabel + \")\"%>" styleClass="pepperoni0" value="0" >No</html:radio>
Radio (html):
<input type="radio" class="pepperoni1" value="1" name="boolean(pepperoniVNever)">Yes
<input type="radio" class="pepperoni0" value="0" name="boolean(pepperoniVNever)">No
Checkbox (jsp):
<html:checkbox property="<%=\"boolean(\" + questionBase + \"V\" + respLabel + \")\"%>" styleClass="pepperoni" />
Checkbox (html):
<input type="checkbox" class="pepperoni" checked="checked" value="on" name="boolean(pepperoniV1)">
I've debugged the application with Eclipse, and following the form object shows that the specific form data is empty when it hits the correlating Action class.
Any ideas as to why the form would correctly submit the checkbox values, but not those of the radio inputs?
Previously radio submissions worked. I'm using struts 1.2.7, Hibernate 3, DisplayTag 1.0, OpenJDk 6, and Tomcat 6 on Ubuntu 14.04.
Aucun commentaire:
Enregistrer un commentaire