How to pass session values from one servlet container to another servlet container? or how can we get session values of one container in another container?
Answer Posted / vemula bojjanna
by using setAttribute()and getAttribute()
for example list is one variable in one servlet like
List l=new list();
l.add("bujji");
l.add("vemula");
u set this value from this servlet by using
req.setAtribute("list",l);
by using getAtribute() u can use the list value of first
servlet into second servlet like
req.getAtribut(list);
| Is This Answer Correct ? | 3 Yes | 14 No |
Post New Answer View All Answers
What is http servlet in java?
What is Client-Server Computing?
What is java servlet session?
How will two or three servlets interact or communicate with each other?
What do you mean by request dispatcher in servlet? Also explain its methods.
Which HTTP method is non-idempotent?
how to link html file to sevlet file.one name is textbox,c&c++ is cheakbox,bc&mca is radio button and one submit buttonis ok why in this programme use in servelt file
Why do we have servlet listeners?
What is servlet invoker?
What are the different session tracking techniques?
How can we implement a jsp page?
What is a web container and what is its responsibility?
What are the different methods involved in generic servlet?
What do you mean by web applications? Explain web application directory arrangement?
What is the use of attribute in servlets?