my dog learned polymorphism*
The moose likes Servlets and the fly likes creating session in JSP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "creating session in JSP" Watch "creating session in JSP" New topic
Author

creating session in JSP

praveen_i
Greenhorn

Joined: Jul 24, 2001
Posts: 3
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

Joined: Mar 22, 2000
Posts: 12761
    
    5
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

Joined: Jun 03, 2000
Posts: 5040

"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

Take a Minute, Donate an Hour, Change a Life
http://www.ashanet.org/workanhour/2006/?r=Javaranch_ML&a=81
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: creating session in JSP
 
Similar Threads
Private Chat
Problem in RMI based chat server...
how to change my client side from JSP to Swing bra
Study Group.
Applet Warning????????