• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Using Validator in struts.

 
Subrata Biswas
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

How to split validator-rules.xml file into multiple files in struts framework? Any Idea please?

With advance thanks
Subrata Biswas.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64717
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please be sure to post Struts questions in the Struts forum. I have moved this post there for you.
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Did you try the documentation?
 
Subrata Biswas
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Thanks, for your reply. I think I have got me wrong. That linked document tells me how to use it.
But My Query is not exactly that one. We need validator-rules.xml and validation.xml. Anyhow we have option to change the name also. Again I can specify different validation.xml like validation1.xml,validation2.xml,...validationN.xml. And we need to give the entry in struts-config.xml with coma separated. My query if I can break validation-rules.xml into multiple files?
If we can do it than for a big application we can split our all validator-rules to make it more maintainable.
 
Aditya Keyal
Ranch Hand
Posts: 71
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes you can. Just mention the same in the struts-config.
 
Subrata Biswas
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do you mean I need multiple file with different info but with the same format?
so I can have validator-rules-1.xml,validator-rules-2.xml.... and so on?
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes. (Wouldn't it have been quicker to just try it? ;)
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic