File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

SEVERE error in application

 
Mary Chellapa
Ranch Hand
Posts: 93
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Tomcat 6/ Struts 2.2.3 in eclipse

in my struts.xml file the IDE is showing a little cross (means error) , when i hover over it, says "The processing instruction target matching [xX][mM][lL] not allowed'

I googled about it, it means there is some space before it . I don't see any space, this is something else.

Can someone please help. Its been quiet sometime i am stuck on it.


Also, i get this error when i run the application


.....
SEVERE: Exception starting filter struts2
java.lang.NoClassDefFoundError: org/apache/commons/lang/StringUtils
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(XmlConfigurationProvider.java:198)
......
 
khekhone yvan
Ranch Hand
Posts: 79
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i think you miss jar

common.something..
add them and restart server
 
Mary Chellapa
Ranch Hand
Posts: 93
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well So many edits but i found the solution and i will post it here ( if it may benefit anyone )

the jars needed were

commons-fileupload-1.2.2.jar
commons-io-2.0.1.jar
commons-lang-2.5.jar
commons-logging-1.1.1.jar
commons-logging-api-1.1.jar
commons-validator-1.3.1.jar
freemarker-2.3.16.jar
javaassist.jar ( you need to get this from jboss site rest you'll get from struts2.2.3)
ognl-3.0.1.jar
struts2-core-2.2.3.jar
xwork-2.1.2.jar (IMP: 2.0 will NOT DO)
xwork-core-2.2.3.jar


And i was getting The processing instruction target matching "[xX][mM][lL]" is not allowed.
for my struts.xml
a lot of googling suggested this problem occurs if there is space before <?xml tag
but my struts.xml didnt have that.

BUTTTT there is a struts.xml inside .metadata folder ( i think its created by tomcat or eclipse .. dont know) there was a space before the tag ( weird i dont know how that happened but i read a lot of people had this issue and i didnt see a solution anywhere )

i am so happy .. its SOME little success with my first struts 2 app ...

 
Mary Chellapa
Ranch Hand
Posts: 93
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think now jars are ok now.


Thanks to the following user as well for suggesting to use blank war... that seems like a good idea too... well next time.
 
khekhone yvan
Ranch Hand
Posts: 79
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
take struts2blank there all jar you need and you can start with it
 
Mary Chellapa
Ranch Hand
Posts: 93
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
..
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic