You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by André de Jesus <an...@tektix.com> on 2001/10/02 14:31:03 UTC

Tomcat 4.0 weirdness setting bean properties from checkboxes

Hi

The following JSP directive:

<jsp:setProperty name="reg" property="*" />

is supposed to work for any CGI parameter coming form an HTML form.

But with HTML form checkboxes, even if the bean function that receives 
the values checks for null or "on", the resulting bean value corresponds 
always to the "true" state. This makes it necessary for a line like this:

reg.setMailShow(request.getParameter("mailShow"));

to be appended in the JSP to explicitly set the value, which would be 
unnecessary if the jsp:setProperty was working correctly.

Is there some way to consistently have a bean function set the value 
correctly?


Thank you

Andre de Jesus