• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Struts 1.3 xml validation is not working

 
sambot dakota
Greenhorn
Posts: 5
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hii
i am making simple login page and trying to validate it using struts ValidatorForm but its not working. But same code worked for DynaValidatorForm. Not able to understand what's problem.
It is not showing any error when i click login button.
here is my code.
login.jsp


LoginAction.java


struts.config



valdiation.xml




thankyou
 
sambot dakota
Greenhorn
Posts: 5
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
anybody please help me..!!!
 
sree hareesh
Greenhorn
Posts: 11
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
post LoginForm.java file
 
sambot dakota
Greenhorn
Posts: 5
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Here is my LoginForm.java
 
jatan bhavsar
Ranch Hand
Posts: 297
Eclipse IDE Java
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Please refer this Link.
In validate method you need to use getter to get the filed on which you would like to put the validation.
Refer the link and let us know if you still find difficulty in validating the fields.

Regards
Jatan
 
sambot dakota
Greenhorn
Posts: 5
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for your reply. But i want xml validation.
 
Vinod Tiwari
Ranch Hand
Posts: 466
1
IntelliJ IDE Java Oracle
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
validate method is part of Validation framework. Please go through validation framework once.
 
Consider Paul's rocket mass heater.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic