validation - Cannot validate component with empty value -


i've got .xhtml file registration page:

<h:inputsecret id="password"                value="#{registracliente.password}"                required="true"                binding="#{password}"                requiredmessage="password obbligatoria"                validatormessage="password non valida">      <f:validateregex pattern="(/^(?=.*\d)(?=.*[a-z])(?=.*[a-z])[0-9a-za-z]{8,}$/)" /> </h:inputsecret> <h:message for="password" style="color:red" />  <h:inputsecret id="confermapassword"                required="true"                value="#{registracliente.confermapassword}"                requiredmessage="devi inserire di nuovo la password">      <f:validator validatorid="passwordvalidator" />     <f:attribute name="password" value="#{password}" /> </h:inputsecret>  <h:message for="confermapassword" style="color:red" /> 

and want this: if 2 input passwords different, shows me error. if they're same, registration allowed. i've added validateregex tag check "strength" of password, that's when got problems. when start server , fill form (writing same password in both input text), should register doesn't, remains on same xhtml page.

eclipse's console gives me warning:

cannot validate component empty value: j_id_4:confermapassword

how comes?

the passwordvalidator (link in comments below) bean implements validator, copied blog post of balusc, who's jsf guru should :d


Comments

Popular posts from this blog

node.js - Using Node without global install -

How to access a php class file from PHPFox framework into javascript code written in simple HTML file? -

java - Null response to php query in android, even though php works properly -