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

Answer Posted / godfather

String str="xxx";
session.setAttribute("xxx",str);//to set session
//so nw the session will get store by the name "xxx".

//To retrieve session

String str1=session.getAttribute("xxx");

Is This Answer Correct ?    14 Yes 10 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why do we use jsp?

494


What is jsp usebean?

501


How can multiple submits due to refresh button clicks be prevented?

574


Which is better jsp or javascript?

498


What is difference between java and jsp?

475






What is the standard action?

527


What is client side technology?

478


What do you mean by isscriptingenabled attribute?

475


Show attributes of page directives.

562


What are the scopes available in ?

515


Perform a browser redirection from a jsp page?

521


How do we catch exception and process it using jstl?

501


What is the jsp:setproperty action?

538


What is the resourcebundle class in jsp?

486


What are the steps for creating custom tags in jsp?

507