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 |
can i call init() method in destroy() method of servlset. ?
What does the term localization refer to?
What are the types of Session Tracking ?
Why is httpservlet declared abstract?
What method is used to create database connection in servlets?
Is it good idea to create servlet constructor?
What are advantages of servlets over cgi?
Differentiate between the print writer and servlet output stream?
What do you mean by httpservlet?
What is the life cycle of a servlet?
What are the key methods that are involved in processing of http servlets?
Describe the phases of servlet lifecycle?