Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Validation Framework in struts2

 
satnam singh negi
Greenhorn
Posts: 25
Hibernate Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi i am working with struts 2 with hibernate .

i want to use validation framework with my application ,and i made ApplicationResources.properties file under src/resources/ .

and the myAction-validation.xml in the package where my action class is located.

but m not able to work with it,i started using a simple text field in my jsp


i have used valdiation framework with struts1.x it was cool there but this is first time m working with struts2. Please suggest


 
Anshul K Jain
Greenhorn
Posts: 20
Hibernate Spring Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
HI satnam,
Try using the validate='true' inside your form tag.


Anshul
 
satnam singh negi
Greenhorn
Posts: 25
Hibernate Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Anshul K Jain wrote:HI satnam,
Try using the validate='true' inside your form tag.


Anshul


i guess this is for client side validation, but in case i want to do some server side validation then i want to use validation framework..and i am able to use it....just need to configure some validation rules with respect to each action ...it pretty simple and good to work with struts validation framework..


thanks for the responses.

cheers
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic