Caused by: Unable to load file:/D:/eclipse-jee-mars-1-win32/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp1/wtpwebapps/dynamicDBsource/WEB-INF/classes/struts.xml - [unknown location]
知道是struts.xml加载失败的问题
<?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE struts PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 2.3//EN" "http://struts.apache.org/dtds/struts-2.3.dtd"> <struts> <constant name="struts.enable.DynamicMethodInvocation" value="true" /> <constant name="struts.devMode" value="true" /> <package name="default" namespace="/" extends="struts-default"> <action name="student_*" class="com.xh.dataSource.action.StuAction" method="{1}"> <result name="addUI">/WEB-INF/view/addUI.jsp</result> <result name="list">/WEB-INF/view/list.jsp</result> <result name="add">/WEB-INF/view/list.jsp</result> </action> </package> </struts>
可是检查N遍都没发现问题。
对比以前的项目,发现:
"-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"
修改后OK
时间: 2024-10-03 12:29:20