Allow one session only at a time

后端 未结 6 1324
予麋鹿
予麋鹿 2020-11-28 13:23

I would like to make my website to allow only one session at a time. For example, let say user has login to my website on firefox, if the user login again to another browser

6条回答
  •  佛祖请我去吃肉
    2020-11-28 13:31

    Keep a central database table or text file of who is logged in at the moment. If a user is already logged in in another session, invalidate that session by setting the "logged in" flag to false.

提交回复
热议问题