I'm trying to make my page more efficient and so I got the question like below:
Is it possible to forward a new Jsp page with RequestDispatcher into an HTML div from the Servlet?
Like this:
someServlet.java
public void doGet(HttpServletRequest req, HttpServletResponse resp)
throws IOException, ServletException {
// do something to send a page to the HTML div in page.jsp
}
page.jsp
<div> <!-- the forwarded page must inside here --> </div>