Rails and Authlogic. Show currently logged in users -


i have list of logged in users.

this code doesn't work :

<% usersession.all.each |user_session| %>  <% end %> 

@syed-aslam has solution, let authlogic work. check out module authlogic::actsasauthentic::loggedinstatus defines 2 scopes: logged_in, logged_out

your code becomes:

<% user.logged_in.each |user| %>  <% end %> 

p.s. link the rdoc instead of source code, rdoc seems have problems @ moment.


Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -