This week's book giveaway is in the Design forum.
We're giving away four copies of Design for the Mind and have Victor S. Yocco on-line!
See this thread for details.
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

creating session in JSP

 
praveen_i
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm doing a chat program ,wherein i have to display all the users who have logged in,i'll be creating a session for each user who logs into the chat.But the problem is,there r multiple chat rooms ,how to keep track of which user is in which room??Maybe,this may seem like a simple question,but please do help me in this regard?
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13058
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The simplest thing to do is store that kind of information in a HttpSession object. In a JSP you automatically get a session object unless you turn it off.
Bill

------------------
author of:
 
Madhav Lakkapragada
Ranch Hand
Posts: 5040
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

"praveen_i"
your name doesn't agree with the javaranch guidelines.
please take a moment and re-register after reviewing the
guidelines at http://www.javaranch.com/name.jsp
thanks for your cooperation.
- satya
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic