java - struts Action 映射 Action 输入属性

标签 java struts-config

在谈到 Java 和 Struts 时,我是个菜鸟(我觉得自己像 Java 世界中的 .Net 男孩)。

action 元素的 input 属性是做什么用的?所以在下面的例子中,输入是 someinput.jsp。

<action path="/somepath" 
        type="SomeAction" 
        name="SomeForm" 
        scope="session"
        input="someinput.jsp">

最佳答案

如果表单bean SomeForm 返回验证错误,它将返回页面someinput.jsp。引用 corresponding DTD :

Valid only when "name" is specified. Required if "name" is specified and the input bean returns validation errors. Optional if "name" is specified and the input bean does not return validation errors.

关于java - struts Action 映射 Action 输入属性,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6644861/

相关文章:

java - 解析 struts.xml 时在 Struts 2 中不使用速度的异常

java - HTTP 状态 500 - Struts1 中的路径没有操作实例

java - 你能在struts-config.xml中使用正则表达式吗?

java - Android Vitals 和异常处理

java - 了解 UI 线程

Java 8 : How BiFunction works while using andThen() and apply() methods

jakarta-ee - 请求的资源在struts2中不可用

java - TreeModel 接口(interface)中的方法 valueForPathChanged (Swing)

java - 如何更改Eclipse帮助打开模式

java - 如何为一个servlet映射多个url