开发者

Reliable session expiration warning using Classic ASP? JQuery?

开发者 https://www.devze.com 2023-03-24 12:59 出处:网络
开发者_C百科I\'m still maintaining a classic asp app and when session goes, the legacy code doesn\'t do anything. I\'d like to issue a warning before session expires and give the user a \"are you stil
开发者_C百科

I'm still maintaining a classic asp app and when session goes, the legacy code doesn't do anything. I'd like to issue a warning before session expires and give the user a "are you still working?" prompt, probably as a modal JQuery window.

Can someone point me to a resource on how to do this reliably? I'm loathe to experiment myself on an older platform. The site is running on Classic ASP 3.0 in 32-bit mode under Windows 2003 Server 64-bit.


I wouldn't ask for the user's input. If the browser window is open, assume the user is working, or why else would it still be open?. If you wait for him saying he's there, it might be too late.

As for an implementation, simply send an ajax request to a dummy ping page every 15mins with setTimeout. Doesn't get any simpler than that!

0

精彩评论

暂无评论...
验证码 换一张
取 消