Feb 21, 2017 06:00 AM|Cathy Zou|LINK
You Can do it by many ways, simple approach is
1.Set one flag at the time of login into database.
2.Check flag every time when you are sign in.
3. Remove flag at time of logout.
You also could use the way in the following link: