remember that this issue should be on demand not every period of time. it is better to do it usin javascript/ajax
John Andersen said the truth... the last activity time... but the 5 minutes is something too long... heheh I do like the way On Oct 15, 12:22 am, DigitalDude <e.blumsten...@googlemail.com> wrote: > Hey, > > that sounds nice, I think I'll give it a try and make an example of > this. > I think most apps use a separate Javascript-Client for these purposes, > but > I have to look for infos about that a little longer the next few > weeks... > > Regards, > > DD > > On 13 Okt., 07:39, John Andersen <j.andersen...@gmail.com> wrote: > > > > > Add a last activity time field, and update it whenever the user does > > something on the site. > > If the user has not done anything for 5 min, show the usersonlinestatusas > > away. > > If the user has not done anything for 10 min, show the usersonlinestatusas > > offline. > > > If a user has a contact (friend) relationship with another user, and > > the other user logs in, then using the contact relationship, add a > > note to the user, that the other user has logged in and delete the > > note when it has been presented. > > > Best wishes, > > John > > > On Oct 12, 4:07 am, DigitalDude <e.blumsten...@googlemail.com> wrote: > > > > Hey, > > > > I need to figure out a solution for a problem. Let's say I have an app > > > which is controlled beiAuthand ACL, so the user can log in into a > > > system and do stuff. > > > > Everyone knows from several social networks or chat clients that when > > > a user is logged in, and one or more friends areonline, too, the > > >statusof these users is shown. > > > > The question is, how could I do such a thing in Cake? Is there any > > > chance to retriebe thestatusof a user, and "flag" it so another user > > > (which is his/her friend or so) can see that he's actually "online"? > > > > I think I could use a flag in the user's table like "online" with 1 or > > > 0 as flag, and set the "online"-statusto 1 as a user logs in. But if > > > a user does not log out, maybe because he just closes the browser, > > > there is no way to set thestatusback to 0 so an indicator could show > > > the user as "offline" (which means, that the field "online" would be > > > set back to 0). > > > > I'm very interested in solutions for such problems, so if you have any > > > suggestions, please let me know. > > > > Regards, > > > > DD- Hide quoted text - > > - Show quoted text - --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---