how to maintain sessions in jsp?can you tellme the methods.
Answer Posted / murali mohan rao
first set the value in session using following methods
***Don't create the unnecessary Strings***
<%session.setAttribute("user","Murali");%>
Below statement you can use in any JSP to print the
welcome message. Start using JSP tags to better performance
and better coding.
Welcome to <%=session.getAttribute("user")%>
| Is This Answer Correct ? | 8 Yes | 3 No |
Post New Answer View All Answers
Define JSP Scriptlet.
What is difference between sendredirect and forward?
A jsp page, include.jsp, has a instance variable "int a", now this page is statically included in another jsp page, index.jsp, which has a instance variable "int a" declared. What happens when the index.jsp page is requested by the client?
Why do we use jsp?
What class.forname will do while loading drivers?
Define Expression
How to deactivate el usage on jsp?
What is auto-flush attribute?
Why is _jspservice () method starting with an '_'?
Can we override jsp service method?
What are the 3 tags used in jsp bean development?
How can we handle the exceptions in jsp?
Explain client-side and server-side validation.
How can I prevent the use of scripts and java code on the jsp page?
Which jsp lifecycle methods can be overridden?