Displaying 1 result from an estimated 1 matches for "teachers_onlin".
Did you mean:
teachers_online
2006 Nov 04
0
using sessions to find who is online
...tore my sessions using the ActiveRecord Store. When
users logout, the session is erased from the database.
I would like to be able to determine who is online at any particular time by
looking at this session table. I have a Session object, and tried this:
@current_sessions = Session.find(:all)
@teachers_online = []
@current_sessions.each do |sess|
@teachers_online << User.find(sess[:user])
end
But that doesn''t work. Rails doesn''t seem to see these sessions like "real"
sessions.
Does anyone know how to make this work?
Thanks,
Shelby
-------------- next part ---...