Don't the users need to log in (maybe using a password) before they can start chatting? That would provide you with the name sof all users online. You could drop someone from the list once they haven't posted in N minutes. Or the client applet could ping the server every so often, and if stops doing do, it must have been closed, so the user is definitely offline.
Joined: Jul 05, 2007
that is okay. but is there any information stored on a cookie or servlet session showing weither a browser is closed or not?
Joined: Mar 22, 2005
Cookies and session store whatever you put in there. Nothing is put there automatically for you.
If you want to make a guess when the applet or browser has been closed, then you can do what I suggested (i.e., the client needs to ping the server in regular intervals).