Time-outs in LC Server?

Alex Tweedly alex at tweedly.net
Fri Jul 19 21:47:05 EDT 2019

On 19/07/2019 14:28, Rick Harrison via use-livecode wrote:
> The following is a link to the javascript stuff I had referred
> to before.  I just want a clean LC way to do the same thing.
> https://stackoverflow.com/questions/9564602/how-to-know-browser-idle-time?noredirect=1&lq=1
Sorry to be the bearer of bad news, but there is no such thing, and 
indeed, there cannot be!

That javascript code runs *in the user's browser", and so can easily 
keep track of idle time. or remaining time

Your LC code can only run on the server. And on the server, all you can 
do is - at the start of responding to a request - check how long it has 
been since the previous request from same user.

So that requires some storage between requests - whether in a database, 
or via cookie / session variable.


More information about the Use-livecode mailing list