No result defined for action xxx result xxx问题

 struts2-convention-plugin-2.1.8.1.jar中需要以下配置

struts2-convention-plugin-2.1.8.1.jar这个包,自动根据访问的url,根据约定找到你请求的jsp页面,或者fremakker页面.

 

在struts.xml中增加

<constant name="struts.convention.result.path" value="/" />

这个配置,就解决问题.

http://127.0.0.1:8080/dbc/test/begin!xx.d

BeginAction中的xx方法已经执行,只是跳转的时候找不到页面.

因为系统不知道指定页面的地址.

增加配置后,就能正常转向页面.

 

 

 

报错信息:

Struts Problem Report

Struts has detected an unhandled exception:

Messages: No result defined for action com.hupun.dbc.action.test.BeginAction and result xx

Stacktraces

No result defined for action com.hupun.dbc.action.test.BeginAction and result xx
    com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:364)
    com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:266)
    com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:165)
    com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87)
    com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:237)
    com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:252)
    org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:68)
    com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87)
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值