在浏览器或选项卡关闭时终止会话 [英] kill the session when the browser or tab is closed

查看:66
本文介绍了在浏览器或选项卡关闭时终止会话的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

how can I kill the session when the user closes the browser?because my server Going to slow down.any one can help me??

推荐答案

Http是无状态的,因此您无法确定地捕获该事件。您可以实现heartbeet - 但在您的情况下,它可能会使服务器速度更慢和/或您需要将会话超时设置为更低的值。但是你受到应用程序使用模型的限制。



最好做一些性能检查和调整。您的应用程序可能需要一些整容。它真的是ASP经典吗?
Http is stateless so you can not catch that event with certainty. You either implement heartbeet - but in your situation it might slow down server even more and/or you will need to set the session timeout to a lower value. But you are constrained by the application usage model.

Better do some performance checkup and tuning. Your application might need some face-lifting. Is it really ASP classic?


这篇关于在浏览器或选项卡关闭时终止会话的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆