Processing HTML Forms by Servlets
In the form tag on the HTML page, you can put the action field to be a JSP page.
This is compiled to be a servlet and the request and response parameters can be explicitly used in a scriptlet on the page. request.getParameter (“username”);where username is the name of a field on the form.
The request object implements javax.servlet.HttpServletRequest and has the following methods, among others:
- getRequest
- getParameterNames
- getParameterValues
- getParameter