Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Not getting the validation message in my example.

 
Rahul Ba
Ranch Hand
Posts: 210
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hi all,

I am trying to code some of the basic example in spring.In the following code, I am not able to show validation messages.


index.jsp




2.loginFormController.java







3.LogonFormValidator.java




4.springapp-servlet.xml






Question: so, when I do not enter anything in username input field, I am not able to see error messages? Any reason?

Thanks in advance.

Rahul
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Don't know, but wouldn't you want to validate the password regardless of username validation failure?
 
Rahul Ba
Ranch Hand
Posts: 210
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi david,

No, I am just learning the Spring MVC ..hence just want to validate username.

Rahul
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hmm. Well, more often than not, it's nicer to the user to give them all the error messages at once, rather than making them fill out the form n times.
 
Hong Anderson
Ranch Hand
Posts: 1936
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I recommend to use Spring form tag.
 
I am Arthur, King of the Britons. And this is a tiny ad:
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!