aspose file tools*
The moose likes Struts and the fly likes Exception while loading the validation.xml in strusts Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Exception while loading the validation.xml in strusts" Watch "Exception while loading the validation.xml in strusts" New topic
Author

Exception while loading the validation.xml in strusts

subhash kumar
Ranch Hand

Joined: Jul 14, 2010
Posts: 63
Hi
I am getting the following exception trace while loading the validation.xml in validation framework of struts :


any suggestion will be highly apreciated.

Subhash Kumar
Attitude is everything
Ankit Garg
Sheriff

Joined: Aug 03, 2008
Posts: 9303
    
  17

Can you post your validation.xml file...


SCJP 6 | SCWCD 5 | Javaranch SCJP FAQ | SCWCD Links
Fidel Edwards
Ranch Hand

Joined: Mar 19, 2008
Posts: 231
Hi Subhash,

The error mentioned in Stack Trace is self-explanatory. You can see it clearly says the


It means that your validation.xml was not properly loaded by Container.

Always try to use (or copy) all xml and jar files from Struts-blank.war (version specific). It will help you a lot as you will no need to bother about the DOCTYPE in XML and jar files version.

Regards,

Fidel


God Gave Me Nothing I Wanted, He Gave Me Everything I Needed.
OCPJP6
subhash kumar
Ranch Hand

Joined: Jul 14, 2010
Posts: 63
here is the validation.xml(i have copied from the internet)

David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

What version of commons validator are you actually using?
subhash kumar
Ranch Hand

Joined: Jul 14, 2010
Posts: 63
i am using commons-validator-1.3.1
but i think version mismatch problem is there.
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Well yeah, your XML file indicates an older version.
subhash kumar
Ranch Hand

Joined: Jul 14, 2010
Posts: 63
Yes problem was the version mismatch.
I downloaded all components of struts of the same version and it worked successfully



This topic is resolved.

Ankit, Fidel, David Newton

Thanks a lot for the suggestions.
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Glad you worked it out!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Exception while loading the validation.xml in strusts