Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
所以我需要知道用户是否在线我怎么知道?(我知道使用会员提供者)
并且找不到为此的实现(或教程)?我或多或少了解会员提供者是如何做到的,这样做是最好的选择吗?还是更好的方法?
一些例子会很好
我的项目中的 iam usgin mvc3
You need to store the last activity timestamp in your users table, and update it whenever you receive any HTTP request from a logged-in user.
A user can be considered "online" if their last activity happened recently. (the exact limit is up to you)