Reputation: 9868
I face a problem that when I create the web project , web.xml has not been created. I want
I make a copy of web.xml file from another project and add configurations I want to run the first example of struts 2 framework,since I add the Servlet Filter fom this toturial http://struts.apache.org/2.x/docs/create-struts-2-web-application-with-artifacts-in-web-inf-lib-and-use-ant-to-build-the-application.html
but this exception occur
Unable to load configuration. - bean - jar:file:/D:/f/alaa%20college/year%204/2ed%20semester/Advance%20SW%20application/struts/FirstStrutsTest/build/web/WEB-INF/lib/struts2-gxp-plugin-2.2.3.jar!
/struts-plugin.xml:8:162
Upvotes: 0
Views: 7235
Reputation: 996
<filter>
<filter-name>struts2</filter-name>
<filter-class>org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
Upvotes: 1
Reputation: 13
use java EE 5 version instead of 6 to create web.xml file automatically but I am still facing the problem in demploying struts 2 sample app without plugin
Upvotes: 1
Reputation: 308988
Put the web.xml under /WEB-INF in your WAR file and put struts-plugin.xml in /WEB-INF/classes and try again.
Upvotes: 0