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 |
What do you mean by httpservlet and how it is different from the genericservlet?
What are the security issues in Servlets?
What do you mean by cgi?
What is servlet and its types?
Is Servlet Class Thread safe?????? How to make servlet Thread safe ???
What is the use of servletconfig interface?
How session tracking can be achieved, if your browser doesn't support cookies (or) if cookies are disabled?
How do servlets work?
What are the difference between RMI and Servlets?
without session Id can we do any operations like add,update,edit,delete. I saw Session id is loaded for edit and delete action not for add .so am asking this
What is cookie in servlet?
What is Request Dispatcher?