How two servlets communicate with each other?
Answers were Sorted based on User's Feedback
Servlets communicate with each other with the help of
RequestDispatcher objects.
RequestDispatcher rd=getServletConfig().getNamedDispatcher
(...);
... name used to identify a servlet i.e. name given in the
web.xml in the url-pattern
| Is This Answer Correct ? | 17 Yes | 1 No |
Answer / devendra
Servlets can communiceate with the help of RequestDispacher.
RequestDispacher rd = getRequestDispacher("passing the 2nd servlet url");
rd.forward(rquest,response);
| Is This Answer Correct ? | 6 Yes | 1 No |
How to notify an object in session when session is invalidated or timed-out?
If you want to modify the servlet,will the Webserver need to be ShutDown ?
What is the difference between the servlets and cgi programs?
if u havea .class file ,how can u say whether it is servlet or not ,dont use java decompliler
What is the difference between CGI and Servlet?
What is a servlet?
Difference between java beans & servlets?
How printwriter is different from servletoutputstream?
What is the difference between an applet and a servlet?
15 Answers GCEW, Miracle Solutions,
Explain load on start-up and its importance?
Should I override the service() method?
In which cases Destroy() is invoked?