为了账号安全,请及时绑定邮箱和手机立即绑定

登录页面跳转报错WARNING: Could not find action or result: /imooc_sh/users/Users_login.action

WARNING: Could not find action or result: /imooc_sh/users/Users_login.action

There is no Action mapped for action name Users_login. - [unknown location]

at com.opensymphony.xwork2.DefaultActionProxy.prepare(DefaultActionProxy.java:185)

at org.apache.struts2.impl.StrutsActionProxy.prepare(StrutsActionProxy.java:63)

at org.apache.struts2.impl.StrutsActionProxyFactory.createActionProxy(StrutsActionProxyFactory.java:37)

at com.opensymphony.xwork2.DefaultActionProxyFactory.createActionProxy(DefaultActionProxyFactory.java:58)

at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:554)

at org.apache.struts2.dispatcher.ng.ExecuteOperations.executeAction(ExecuteOperations.java:81)

at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:99)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:291)

at org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:877)

at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:594)

at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1675)

at java.lang.Thread.run(Thread.java:722)


下面是我的struts.xml

<struts>


<package name="default" namespace="/" extends="struts-default">


</package>

<package name="users" namespace="/users" extends="default">

<action name="*_*" class="action.{1}Action" method="{2}">

<result name="login_success">/users/Users_login_success.jsp</result>

<result name="login_failure">/users/Users_login.jsp</result>

</action>

</package>


</struts>

http://img1.sycdn.imooc.com//57976fa700010ca910630651.jpg

正在回答

4 回答

 /**

 * 使用默认的validate()需要在struts.xml配置 

 * <result name="input">/users/Users_login.jsp</result>

 * 才能返回登录页面去显示错误信息

 */


0 回复 有任何疑惑可以回复我~

那怎么搞,

0 回复 有任何疑惑可以回复我~

大家好 这个问题我自己找到了。web项目用添加USER的jar包方法有点问题

引用红发少年的评论:最最最坑爹的问题是,我的Myeclipse 2014和2015都遇到的坑爹问题:千万别用Java - Build path - user library再 项目里add library 我的经验是 最终这个方法进去的包 都只服务本地,不进tomcat

0 回复 有任何疑惑可以回复我~

我自己感觉应该是 struts2-core2.3.24 jar包原因导致的,或许和之前struts2修复漏洞有关?哪位大侠帮我看看

0 回复 有任何疑惑可以回复我~

举报

0/150
提交
取消

登录页面跳转报错WARNING: Could not find action or result: /imooc_sh/users/Users_login.action

我要回答 关注问题
意见反馈 帮助中心 APP下载
官方微信