how to maintain sessions in jsp?can you tellme the methods.
Answer Posted / brindha.d
using session oject in jsp.
first u set using following methods
String name="ravi";
session.setAttribute("user",name);
using retrive method
String sessionuser=session.getAttribute(name);
out.println("welcome"+sessionuser);
u give this last 2 stmts in all jsp pages. it will
display as "Welcome ravi".
| Is This Answer Correct ? | 121 Yes | 55 No |
Post New Answer View All Answers
What are the implicit objects in jsp?
How can you avoid scriptlet code in jsp?
What are the jsp elements?
Differentiate between response.sendredirect(url) and
Which is mandatory in tag in jsp?
Can you call jsp from servlet?
Explain the steps for creating custom tags in jsp?
How do you delete the session data?
What is the advantage of using getProperty action, as compared to the accessor method?
Why is it not necessary to configure standard jsp tags in web.xml?
How can a thread safe JSP page be implemented?
Why is _jspservice() method starting with an '_' while other life cycle methods do not?
What is an implicit object?
what is the difference between jsp and servlets ?
What is session object in jsp?