Skip to content

Instantly share code, notes, and snippets.

@raunakhajela
Created January 11, 2018 07:26
Show Gist options
  • Save raunakhajela/b015bea7c9acc35f010fc1668dba1c2b to your computer and use it in GitHub Desktop.
Save raunakhajela/b015bea7c9acc35f010fc1668dba1c2b to your computer and use it in GitHub Desktop.
JSP: Forms
<html>
<body>
<form action="student-response.jsp">
First name: <input type="text" name="fname" />
<br/><br/>
Last name: <input type="text" name="lname" />
<br/><br/>
<input type="submit" value="Submit" />
</form>
</body>
</html>
<html>
<body>
The student is confirmed: ${param.fname} ${param.lname}
<br/><br/>
The student is confirmed: <%= request.getParameter("fname") %> <%= request.getParameter("lname") %>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment