沙漠中的鱼

欲上天堂,先下地狱
posts - 0, comments - 56, trackbacks - 0, articles - 119
  BlogJava :: 首页 ::  :: 联系 :: 聚合  :: 管理

No result defined for action and result input

Posted on 2009-01-06 21:41 沙漠中的鱼 阅读(28872) 评论(21)  编辑  收藏 所属分类: 开源框架
这是struts2的一个拦截器报的错误,当你的form中的数据有问题,比如说
<input type="text" name="receiverLoginID" value="<%=name%>"/>
当 name值为NULL时,就出这个错了,所以你可以在当前页面加入以下标签
<div style="color:red">
    <s:fielderror />
</div>
它就会显示拦截器的错误,并在struts的XML中对应action里加如
<result name="input">/AddProducts.jsp</result>
让他把错误返回到该页面就可以了

评论

# re: No result defined for action and result input  回复  更多评论   

2009-10-31 15:06 by 丑孩
谢过了,呵呵

郁闷死我了,

老告诉我 没有 result,

呵呵~~~~~

# re: No result defined for action and result input  回复  更多评论   

2009-11-24 17:08 by yezi1305
一语中的!多谢

# re: No result defined for action and result input[未登录]  回复  更多评论   

2010-02-05 15:25 by dd
多谢

# re: No result defined for action and result input  回复  更多评论   

2010-05-26 07:22 by 杜莹
太感谢了~~~~~~~~
我被这种错误折磨了一天,就连晚上都在做噩梦,如果不是你,我今天晚上又要做恶梦了。。。。。。
认识一下吧,我的QQ是1021807894,全天在线

# re: No result defined for action and result input  回复  更多评论   

2011-02-26 17:24 by 游人
非常感谢,也是一语点中,马上就找到错误了。

# re: No result defined for action and result input  回复  更多评论   

2011-03-13 13:45 by footman
易于惊醒梦中人

# re: No result defined for action and result input  回复  更多评论   

2011-05-23 17:36 by 孙沫
超级感谢

# re: No result defined for action and result input  回复  更多评论   

2011-06-14 17:07 by 陈军
非常感谢

# re: No result defined for action and result input  回复  更多评论   

2011-07-11 16:09 by 淡定
受教了

# re: No result defined for action and result input  回复  更多评论   

2011-07-13 14:16 by 张辉武
感谢,Struts2的错误提示真是服了

# re: No result defined for action and result input  回复  更多评论   

2012-02-27 13:36 by 禾谷
多谢

# re: No result defined for action and result input[未登录]  回复  更多评论   

2012-04-12 09:50 by allen
感激涕零

# re: No result defined for action and result input[未登录]  回复  更多评论   

2012-04-19 21:23 by 呵呵
太感谢了!为了这个错误我找了半天,就打错了个字母,非常感谢你哈!

# re: No result defined for action and result input  回复  更多评论   

2012-04-26 12:25 by 猪猪次品
在没看见你的解答之前,我几乎奔溃了,怎么就没有result了呢,这个myeclipse小贱人,多谢您老啦,哎,有经验就是好啊,不会被这个问题纠结啊,以后遇到问题还是多百度一下,不要自己一个人纠结啦

# re: No result defined for action and result input  回复  更多评论   

2012-04-28 15:26 by 咔咔
感激不尽,都快疯啦!高手不一样啊

# re: No result defined for action and result input  回复  更多评论   

2012-08-07 15:37 by xiaohuasi
怎么解决的,我也遇到这个问题,不过如果我不给action请求带参数就没问题

# re: No result defined for action and result input  回复  更多评论   

2012-12-15 16:20 by ss
高手 ,牛逼,确实是你说的问题

# re: No result defined for action and result input[未登录]  回复  更多评论   

2013-01-10 01:48 by Terry
牛逼,困扰一个下午的问题解决了

# re: No result defined for action and result input  回复  更多评论   

2013-06-06 10:35 by baiyuxiong
表单数据有错,也会报这个错误。
我的表单里提交了两个同样的值:
cateList[0].cid
本来应该是
cateList[0].cid
cateList[1].cid
记数弄错了。

# re: No result defined for action and result input[未登录]  回复  更多评论   

2014-12-23 15:56 by 1
有用,牛逼

# re: No result defined for action and result input[未登录]  回复  更多评论   

2015-08-06 20:32 by java小菜
牛逼

只有注册用户登录后才能发表评论。


网站导航: