struts初学者, 求助!!!
报错:Cannot retrieve definition for form bean: "loginForm" on action: "login.do"
login.jsp文件:
<html:form method="POST" action="login.do">
登录窗口<br>用户名
<html:text property="username" name="username"></html:text>
<br>密码 <html:password redisplay="true" property="password" name="password"></html:password>
<br><html:submit value="登录" property="submit">
</html:submit>
<a href="register.jsp"></a>
</html:form>
struts-config.xml文件:
<form-beans >
<form-bean name="loginForm" type="com.yourcompany.struts.forms.LoginForm"></form-bean>
</form-beans>
<action-mappings >
<action path="/index" forward="/login.jsp"/>
<action
input="/login.jsp"
name="loginForm"
path="/login"
scope="request"
type="com.yourcompany.struts.actions.LoginAction"
>
<forward name="success" path="/welcome.jsp"/>
<forward name="failure" path="/login.jsp"/>
</action>
</action-mappings>
------解决方案--------------------
如需要阅读该回复,请登录或注册CSDN!
------解决方案--------------------
如需要阅读该回复,请登录或注册CSDN!