简体   繁体   English

Struts2操作未从URL调用

[英]Struts2 Action Not Calling from url

String url = ipaddressPortnumber + request.getContextPath() + "/registerconfig.action?lvd=" + lvd;

lvd is a class; lvd是一类; when i want to hit on the action (registerconfig.action?lvd="+lvd) given on url got a error like below, how can i solve it 当我想点击url给出的操作(registerconfig.action?lvd="+lvd)时遇到如下错误,我该如何解决 按下操作按钮后出现错误页面

The result input is required to add to the action config because before executing the action it has validation errors. 需要将结果input添加到操作配置中,因为在执行操作之前,它具有验证错误。 The flow will return back to the index.jsp where you can fix errors before submitting the form. 该流程将返回到index.jsp ,您可以在其中修复提交表单之前的错误。 The action won't execute if it has errors. 如果该操作有错误,则不会执行。 Add this code to the action config 将此代码添加到操作配置

<result name="input">index.jsp</result>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM