On Wednesday, June 10, 2015 at 8:32:33 AM UTC-7, Alex Glaros wrote: > > What is best approach to redirect user to their account home page only > when logging in for the first time each day? > > I want to avoid redirecting to their home page when session times out, > because then user loses their place when they re-login and gets taken away > from what they were working on. > > My guess would be to add an extra field to auth_users, and to toggle (or reset) that field on the first login of the day, and set it when they log out. I was going to suggest a session variable, but if you're clearing the session on expiration, that could be unsatisfactory.
What about someone who is logged in and working just before midnight, and the session times out the next day. (12:01 am, or 00:01)? Do you set the flag then, or continue to allow "resume"? What about someone who never logs out? (I don't think those are technically difficult to handle, just pointing out that you may have to handle those cases.) /dps -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.

