Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to create Session

 
Rameez Shaik
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I created a web application where i need to include Sessions management.

Lets consider three pages "Login.html", "Validation.java" (servlet) , "HomePage.jsp";

In the login.html form i have set action as Validation.java which is a servlet for validation of data from database.

And when Validation is successful then it directs to homepage.jsp . I want to know how to set Session for this application.

I have tried following steps but unable to go through.

> i have set the session in homepage.jsp as



But i get the session as null. please let me know if any thing i am missing?

Thanks
Rameez.



 
mallikarjun dontamsetti
Ranch Hand
Posts: 246
Firefox Browser Oracle
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
First validate user in Servlet and then write like this


get that session in jsp use JSTL not Scriptlets
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic