Struts View Components: ActionForm Objects
Here is the JSP page
(login.jsp) that creates the login screen.
- Note that the action attribute on the html:form tag has
value "login"
- Recall the Login
Action mapping element from struts-config.xml
- When the framework receives a login request, it takes the request
parameters and puts them into an instance of a LoginForm object
- The LoginForm class, written by the developer, extends the
framework's ActionForm
class
- An ActionForm object is passed as a parameter to the
execute() method in the Action class (extended in this
example by LoginAction)