Answer the question
In order to leave comments, you need to log in
How to set time for sessions in Ruby on Rails???
I want to write a table of visits (date of entry, date of exit) of users.
That's when someone comes in with authorization, then the session is set: session[: user_id].
And here you can immediately determine the date of entry.
But to determine the release date, I think it’s better to write a function that every five minutes will check for session activity (session[:user_id]), and for this you need to set the time for sessions, if for example, if the user is not active, then so that the session is deleted after 5 minutes.
And how it is possible to set time to sessions???
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question