Struts2配置文件

严重:DispatcherinitializationfailedUnabletoloadconfiguration.-action-file:/D:/Program%2... 严重: Dispatcher initialization failed
Unable to load configuration. - action - file:/D:/Program%20Files/Apache%20Software%20Foundation/Tomcat%206.0/webapps/Struts_2/WEB-INF/classes/example.xml:22:73

Caused by: Error building results for action LoginAction_* in namespace / - action - file:/D:/Program%20Files/Apache%20Software%20Foundation/Tomcat%206.0/webapps/Struts_2/WEB-INF/classes/example.xml:22:73
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addAction(XmlConfigurationProvider.java:367)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addPackage(XmlConfigurationProvider.java:468)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.loadPackages(XmlConfigurationProvider.java:264)
at org.apache.struts2.config.StrutsXmlConfigurationProvider.loadPackages(StrutsXmlConfigurationProvider.java:111)
at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:193)
at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:55)
... 31 more
Caused by: There is no result type defined for type 'redirect-action' mapped with name 'success'. Did you mean 'redirectAction'? - result - file:/D:/Program%20Files/Apache%20Software%20Foundation/Tomcat%206.0/webapps/Struts_2/WEB-INF/classes/example.xml:24:50
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.buildResults(XmlConfigurationProvider.java:621)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addAction(XmlConfigurationProvider.java:365)
... 36 more
struts.xml
<package name="mypackage" namespace="/" extends="struts-default">
<action name="LoginAction_*" method="{1}" class="com.tur.LoginAction">
<interceptor-ref name="paramsPrepareParamsStack"/>
<result type="redirect-action" name="success">/main.jsp</result>
<result name="input">/login.jsp</result>
</action>

<action name="crud" method="{1}" class="com.tur.UserAction">
<result name="list">/userList.jsp</result>
<result name="success" type="redirect-action">crud!list</result>
<result name="input">/userForm.jsp</result>
</action>
展开
 我来答
百度网友b0e4c28e95
2010-05-04 · TA获得超过148个赞
知道答主
回答量:81
采纳率:0%
帮助的人:29.9万
展开全部
result type="redirect-action" 改成result type="redirect"
推荐律师服务: 若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询

为你推荐:

下载百度知道APP,抢鲜体验
使用百度知道APP,立即抢鲜体验。你的手机镜头里或许有别人想知道的答案。
扫描二维码下载
×

类别

我们会通过消息、邮箱等方式尽快将举报结果通知您。

说明

0/200

提交
取消

辅 助

模 式