The Forward Action
The jsp:forward action transfers control from the current JSP page to another location on the server.
Some possible uses:
- Send the contents of a display page at the end of a page that mainly does some actions.
- In a conditional scriptlet, forward control to some error page when a particular situation arises.
In some of the earlier servlet examples we used sendRedirect() to transfer to a display page after doing some actions.
Using jsp:forward would be more efficient, because it does not involve the browser in the transfer.