how to maintain sessions in jsp?can you tellme the methods.

Answer Posted / mayur patel

start session oject in jsp.

first u set using following methods
String name="Mayur4453";
session.setAttribute("user",name);

using retrive method
String suser=session.getAttribute("user");**
out.println("Hi. . !! welcome "+suser);

Is This Answer Correct ?    19 Yes 8 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are jsp and servlets?

491


What is the jspdestroy() method?

566


How many jsp implicit objects are there?

493


What is the _jspservice() method?

511


What is response sendredirect?

476






Perform a browser redirection from a jsp page?

529


How to connect jsp and java file?

472


What is application in jsp?

468


Explain implicit objects in jsp?

598


Give an example of using your own tags.

528


Why is jsp used?

497


Which categories can be divided jstl tags, give examples.

518


What are the possible values for language directive?

493


Why session is used?

471


How can you make the finally clause not to fail to execute?

492