You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Paul Wallace <pw...@intelematics.com.au> on 2003/10/06 02:59:36 UTC
control Array
Hi,
How might I request a series of checkboxes that all share the
same name? E.g:
<form>
<input type="checkbox" name="myCheck" value="01">
<input type="checkbox" name="myCheck" value="02">
<input type="checkbox" name="myCheck" value="03">
</form>
I understand in VB something called a control array exists, that
retrieves the checked checkbox values and stores them in an array. This
is also possible in CFM. Is there the equivalent in Java/HTTP? Something
where I DON'T have to do:
<input type="checkbox" name="myCheck1" value="01">
<input type="checkbox" name="myCheck2" value="02">
<input type="checkbox" name="myCheck3" value="03">
<%
for (int i = 0;i < noofCheckboxes; i++) {
myarr[i] = request.getParameter("myCheck" + i);
}
%>
Thanks for any replies, or direction towards doco re this.
Paul.
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org