1
我在struts2中使用struts2-convention-plugin和struts2-config-browser-plugin,如果我更改默認的struts.xml路徑在web.xml中:struts2-convention和struts2-config-browser-plugin不能工作,如果我更改struts.xml路徑
<filter>
<filter-name>struts2</filter-name>
<filter-class>org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter</filter-class>
<init-param>
<param-name>config</param-name>
<param-value>struts-default.xml,struts-plugin.xml,struts/struts.xml</param-value>
</init-param>
</filter>
他們不能再工作了,爲什麼?
我將classpath struts.xml更改爲struts/struts.xml,因此它存在。 –
@TardisXu文件名是錯誤的,它應該是一個正確的文件名,而不是文件路徑或協議。 –
它可以在沒有struts2-convention-plugin的情況下工作。 –