JSF 2 validateLength example

“f:validateLength” is a JSF string length validator tag, which is used to check the length of a string. For example, <h:inputText id="username" value="#{user.username}"> <f:validateLength minimum="5" maximum="10" /> </h:inputText> When this form is submitted, the validator will make sure the “username” text field contains a minimum length of 5, maximum length of 10. “f:validateLength” example A …

Read more