What is the use of RequestDispatcher in servlet?
Answer Posted / tirupathi rao
RequestDispatcher is used to connect to another webresource
with in the same context.
RequestDispatcher
rd=ServletContext.getRequestDispatcher("url of resource");
rd.forward(req,res);----used to forward to another resource.
rd.include(req,res);----used to include other resource.
Is This Answer Correct ? | 132 Yes | 15 No |
Post New Answer View All Answers
What are the supporting protocol by HttpServlet ?
What is SingleThreadModel interface?
What is the advantage of Servlets when compared with other server side technologies?
What are the life cycle methods of the servlet?
How do I support both get and post from the same servlet?
How many servlet objects are created?
What do you mean by servlet context?
What is the purpose of dispatcherservlet properties?
What must be implemented by all servlets?
Why servlet is used as controller ? Not JSP? I want complete explation?
Why HttpServlet class is declared abstract?
What is called Scriptlet?
Which http method is said to be non-idempotent and idempotent?
What are some disadvantages of storing session state in cookies?
How do you invoke a servelt?