The path of an ForwardConfig cannot be null-struts validator验证框架异常
struts validator验证框架异常<div class="cnt">在测试struts validator验证框架的时候,出现了下面的异常:
javax.servlet.ServletException: java.lang.IllegalArgumentException: The path of an ForwardConfig cannot be null
才发现少写了input=""这个属性就会出现那样的异常,因为验证没有通过的话就会调回input指向的页面。
<action-mappings>
<action path="/login"
type="com.struts.LoginAction"
name="loginForm"
scope="request"
validate="true"
input="/login.jsp">
<forward name="success" path="/login_success.jsp" />
</action>
</action-mappings>
页:
[1]