• Post Reply Bookmark Topic Watch Topic
  • New Topic

displaying error message next to text field

 
Varun Nayudu
Ranch Hand
Posts: 159
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have just started learning jsf , i have made a login jsf whichhas to fields username and password. When the user enters the username password and hits the submit button it goes to a java bean where all the validation happens .

For now i have a if else in which it will check the inputted username with the my predefined name.
This ia working fine .depending on the username and password the 2nd jsf is displayed or otherwise the 1st jsf is displayed.

But now i want to show a message on the side of the text fields when the user enters the wrong username and when the 1st jsf is displayed all over again.
i have kept the <h:message /> but what else do i need to do for it to work ....
 
Bauke Scholtz
Ranch Hand
Posts: 2458
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The h:message ought to be sufficient.

What´s your actual problem?
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!