March 31 2015

Jsf email validator

Jsf email validator

f:validateRegex  can be used to validate the email entered by the user.

f:validateRegex tag is used to validate a string value to a required format. Validator checks whether the value of the wrapping component is matching to the pattern or not. If it matches, it is valid otherwise it is not valid.

Syntax

<f:validateRegex pattern=”required pattern” />

The valid pattern for the email is

^[_A-Za-z0-9-\+]+(\.[_A-Za-z0-9-]+)*@[A-Za-z0-9-]+(\.[A-Za-z0-9]+)*(\.[A-Za-z]{2,})$

Example Continue reading

Category: Jsf | LEAVE A COMMENT
November 18 2014

Jsf selectoneradio

The h:selectOneRadio tag renders a set of HTML input element of type “radio”, and format it with HTML table and label tags.

h:selectOneRadio can be used when only one option have to be selected. This Components renders group of radion button and only option can be selected

 

Jsf Page Continue reading

Category: Jsf | LEAVE A COMMENT