How do you pass the data from one servlet to another
servlet?
Answer Posted / tulasi vani
We can pass the data from one servlet to another using
RequestDispatcher object.
1.RequestDispatcher rd=getServletContext.getNamedDispatcher
("...");
rd.forward(request,response);
... means use the name of the url-patterns you have
specified for the servlet in web.xml.
| Is This Answer Correct ? | 34 Yes | 15 No |
Post New Answer View All Answers
Why servlet is used as controller ? Not JSP? I want complete explation?
Is tomcat a servlet container?
How do we go with database connection and log4j integration in servlet?
Explain web application directory arrangement?
Why is it that we can't give relative URL's when using ServletContext.getRequestDispatcher() when we can use the same while calling ServletRequest.getRequestDispatcher()?
What do you mean by cgi and what are its drawbacks?
What is the difference in between the httpservlet and generic servlet?
How to get the current httpsession object?
How does tomcat servlet container work?
What is the difference between genericservlet and httpservlet
What are the new features added to servlet 2.5?
What do you mean by singlethreadmodel interface?
Explain the architechure of a servlet?
What is servlet and how it works?
Elucidate servlet attributes and its scope?