Bear Bibeault wrote:First of all, the obligatory: what are you doing putting Java code into a JSP in 2012? Scriptlets have been discredited since 2002. Time to update your JSP knowledge with the JSTL and EL.
Ok, I should update myself I did it in that way because I thought it was something quick and do not give me so many problems.
Bear Bibeault wrote:When you submit the form, the checkbox value will be sent if the control is checked. Otherwise, nothing will be sent.
I understand that but how I know what data was sent?.
I mean in a regular form with an input with the atribute
id or
name set I only have to use the request to get the value:
But in this case I don't know how many checkboxes I will have and even their names or ids to use getParameter.
Bear Bibeault wrote:The getParameter() call will never throw a NumberFormatException. It's some other code that's doing that. Perhaps some following code that can't deal with null properly.
I didn't know that but there´s no more code in the second jsp than the one I've posted I´m my first post and the exception points me to that line.